Part Number Hot Search : 
80025 AX593 SXQ50 2SB1568 20L45CT 1B23A10 MC14468 2SC47
Product Description
Full Text Search
 

To Download ADE7758ARW Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  poly phase multifunction energy metering ic with per phase information ade7758 rev. a in fo rmation furn ished by an alog d e v i c e s is believed to be accurate and reliable. how e ver, n o resp on sibili ty is assume d b y a n alog de vices fo r its use, nor for an y i n fri n geme nt s of p a t e nt s or ot h e r ri ght s o f th ird parties th at may result fro m its use . specifications subjec t to chan g e witho u t n o tice. no licen s e is g r an te d by implicati o n or ot herwi s e u n der a n y p a t e nt or p a t e nt ri ghts of analog de v i ces. trademarks an d registered tra d ema r ks are the prop erty o f their respective ow ners. one technolog y way, p.o . box 9106, norwood, ma 02062-9106, u.s.a. t e l: 781. 329. 4 700 www.analog.com fax: 781. 326. 87 03 ? 2004 analog de vices, i n c. al l r i ght s r e ser v ed . fea t ures high accuracy, supports iec 6 0687, iec 610 3 6 , iec 61 268, iec 6205 3-21, iec 620 53-2 2 , a n d iec 62 053- 2 3 compatible with 3-phase/3-wi re, 3-phase/4- wire, and other 3-phase ser v ices less than 0.1% active en ergy error over a d y namic range of 1000 to 1 at 2 5 c supplies active /reactive/apparent energy, voltage rms, current rms, an d sample d waveform data two pulse out p uts, one for active power and the other selectable bet w een reactive and apparent power with programmable frequency digital power, phase, and rms offset calibrati o n on-chip user programmable thresholds for li ne voltage s a g and over voltage detections on-chip digital integrator ena b les direct inte rface-to-curren t sensors with di /dt output a pga in the current channel a llows direct int e rface to shunts and cur r ent transformers a spi? compatible serial interf ace with irq proprietary ad cs and dsp provide high accuracy over l a rge variations in e n vironmental conditions and t i me reference 2.4 v (drift 30 ppm/c typ) with external ov erdriv e capability single 5 v supp ly, low power ( 70 mw t y p) gener a l description the ad e7758 1 is a hig h acc u ra c y 3-phas e ele c t r ica l e n erg y m e a s ur e m en t ic w i t h a s e r i a l i n t e r f ac e an d two p u ls e o u t p uts. the ad e7758 in co r p o r a t es s e c o n d -o r d er -? ad cs, a dig i ta l in teg r a t o r , r e fer e n c e cir c ui t r y , tem p er a t ur e s e ns o r , a nd al l t h e s i g n a l pro c e s s i ng re qu i r e d to p e r f or m ac t i ve, re ac t i ve, and a p p a r e n t e n erg y m e as ur emen t and r m s calc u l a t i o n s . the ad e7758 is s u i t ab le t o m e as ur e ac ti v e , r e ac ti v e , and a p p a r e n t e n erg y in va r i o u s 3-ph as e co nf igura t ion s , such as wye o r d e l t a s e r v ices , b o t h wi t h t h r e e o r fo ur wir e s. the ad e7758 p r o v ides sys t em cal i b r a t io n f e a t ur es f o r eac h p has e , i . e ., r m s o f fs et c o r r e c t i o n , phas e cal i b r a t io n, and p o w e r c a li b r a t i o n . th e a p c f l o gi c o u t p u t gi v e s a c ti v e po w e r info r m a t io n, and t h e v a rcf lo g i c o u t p ut p r o v i d es in st an t a n e o u s re ac t i v e o r a p p a ren t p o w e r info r m a t io n . ( c ont i nu e d on pa g e 4 ) func ti on a l bl ock di a g r a m 04443- 0- 001 phase b and phase c data 4 avdd power supply monitor 12 ref in/out 11 agnd adc ? + 9 icp 10 icn pga1 adc ? + 14 vcp 13 vn pga2 active/reactive/apparent energies and voltage/current rms calculation for phase c (see phase a for detailed signal path) adc ? + 7 ibp 8 ibn pga1 adc ? + 15 vbp pga2 active/reactive/apparent energies and voltage/current rms calculation for phase b (see phase a for detailed signal path) adc ? + 5 iap 6 ian pga1 adc ? + 16 vap pga2 aigain[11:0] avrmsgain[11:0] avag[11:0] x 2 aphcal[6:0] hpf integrator dt avaros[11:0] avarg[11:0] lpf2 90 phase shifting filter 2 awattos[11:0] awg[11:0] lpf2 22 din 24 dout 23 sclk 21 cs 18 irq ade7758 registers and serial interface wdiv[7:0] % vardiv[7:0] % vadiv[7:0] % airmsos[11:0] x 2 lpf 2.4v ref 4k ? dfc apcfnum[11:0] apcfden[11:0] active power 1 apcf 3 dvdd 2 dgnd 19 clkin 20 clkout dfc varcfnum[11:0] varcfden[11:0] reactive or apparent power 17 varcf ade7758 avrmsos[11:0] 1 patents pend in g. fi g u r e 1 .
ade7758 rev. a | page 2 of 68 table of contents specifications..................................................................................... 5 timing characteristics..................................................................... 7 absolute maximum ratings............................................................ 9 esd caution.................................................................................. 9 pin configuration and function descriptions........................... 10 terminology .................................................................................... 12 typical performance characteristics ........................................... 13 theory of operation ...................................................................... 19 antialiasing filter ....................................................................... 19 analog inputs.............................................................................. 19 current channel adc............................................................... 20 di/dt current sensor and digital integrator ........................... 21 peak current detection ............................................................. 22 overcurrent detection interrupt ............................................. 22 voltage channel adc ............................................................... 22 zero-crossing detection........................................................... 24 phase compensation.................................................................. 24 period measurement .................................................................. 26 line voltage sag detection ..................................................... 26 sag level set.............................................................................. 26 peak voltage detection.............................................................. 26 phase sequence detection......................................................... 27 power-supply monitor............................................................... 27 reference circuit ........................................................................ 28 temperature measurement ....................................................... 28 root mean square measurement ............................................. 28 active power calculation .......................................................... 30 reactive power calculation ...................................................... 35 apparent power calculation..................................................... 38 energy registers scaling ........................................................... 41 waveform sampling mode ....................................................... 41 calibration................................................................................... 41 checksum register..................................................................... 54 ade7758 interrupts................................................................... 54 using the ade7758 interrupts with an mcu........................ 54 interrupt timing ........................................................................ 55 ade7758 serial interface.......................................................... 55 ade7758 serial write operation ............................................ 56 ade7758 serial read operation ............................................. 57 accessing the ade7758 on-chip registers........................... 58 communications register......................................................... 58 operational mode register (0x13) .......................................... 61 measurement mode register (0x14) ....................................... 62 waveform mode register (0x15) ............................................. 62 computational mode register (0x16)..................................... 63 line cycle accumulation mode register (0x17) ................... 64 interrupt mask register (0x18) ................................................ 65 interrupt status register (0x19)/reset interrupt status register (0x1a)........................................................................... 66 outline dimensions ....................................................................... 67 ordering guide .......................................................................... 67
ade7758 rev. a | page 3 of 68 revision history 9/04changed from rev. 0 to rev. a changed hexadecimal notation ...................................... universal changes to features list...................................................................1 changes to specifications table ......................................................5 change to figure 25 ........................................................................16 additions to the analog inputs section.......................................19 added figures 36 and 37; renumbered subsequent figures ....19 changes to period measurement section ....................................26 change to peak voltage detection section..................................26 added figure 60 ..............................................................................27 change to the current rms offset compensation section......29 edits to active power frequency output section.......................33 added figure 68; renumbered subsequent figures ..................33 changes to reactive power frequency output section.............37 added figure 73; renumbered subsequent figures ..................38 change to gain calibration using pulse output example .......44 changes to equation 37 .................................................................45 changes to examplephase calibration of phase a using pulse output ..................................................................45 changes to equations 56 and 57 ...................................................53 addition to the ade7758 interrupts section .............................54 changes to example-calibration of rms offsets ......................54 addition to table 20 .......................................................................66 1/04revision 0: initial version
ade7758 rev. a | page 4 of 68 general description (continued from page 1) the ade7758 has a waveform sample register that allows access to the adc outputs. the part also incorporates a detection circuit for short duration low or high voltage variations. the voltage threshold levels and the duration (number of half-line cycles) of the variation are user programmable. a zero-crossing detection is synchronized with the zero-crossing point of the line voltage of any of the three phases. this information can be used to measure the period of any one of the three voltage inputs. it is also used internally to the chip in the line cycle energy accu- mulation mode. this mode permits faster and more accurate calibration by synchronizing the energy accumulation with an integer number of line cycles. data is read from the ade7758 via the spi serial interface. the interrupt request output ( irq ) is an open-drain, active low logic output. the irq output goes active low when one or more interrupt events have occurred in the ade7758. a status register indicates the nature of the interrupt. the ade7758 is available in a 24-lead soic package.
ade7758 rev. a | page 5 of 68 specifications 1, 2 avdd = dvdd = 5 v 5%, agnd = dgnd = 0 v, on-chip reference, clkin = 10 mhz xtal, t min to t max = ?40c to +85c. table 1. parameter specification unit test conditions/comments accuracy active energy measurement error (per phase) 0.1 % typ over a dynamic range of 1000 to 1 phase error between channels line frequency = 45 hz to 65 hz, hpf on (pf = 0.8 capacitive) 0.05 max phase lead 37 (pf = 0.5 inductive) 0.05 max phase lag 60 ac power supply rejection 1 avdd = dvdd = 5 v + 175 mv rms/120 hz output frequency variation 0.01 % typ v1p = v2p = v3p = 100 mv rms dc power supply rejection 1 avdd = dvdd = 5 v 250 mv dc output frequency variation 0.01 % typ v1p = v2p = v3p = 100 mv rms active power measurement bandwidth 14 khz irms measurement error 0.5 % typ over a dynamic range of 500:1 irms measurement bandwidth 14 khz vrms measurement error 0.5 % typ over a dynamic range of 20:1 vrms measurement bandwidth 260 hz analog inputs see the analog inputs section maximum signal levels 500 mv max differential input input impedance (dc) 380 k? min adc offset error 3 30 mv max uncalibrated error, see the terminology section gain error 1, 3 6 % typ external 2.5 v reference waveform sampling sampling clkin/128, 10 mhz/128 = 78.1 ksps current channels see the current channel adc section signal-to-noise plus distortion 62 db typ bandwidth (?3 db) 14 khz voltage channels see the voltage channel adc section signal-to-noise plus distortion 62 db typ bandwidth (?3 db) 180 hz reference input ref in/out input voltage range 2.7 v max 2.5 v + 8% 2.3 v min 2.5 v C 8% input capacitance 10 pf max on-chip reference nominal 2.4 v at ref in/out pin reference error 200 mv max current source 6 a max output impedance 4 k? min temperature coefficient 30 ppm/c typ clkin all specifications clkin of 10 mhz input clock frequency 15 mhz max 5 mhz min logic inputs din, sclk, clkin, and cs input high voltage, v inh 2.4 v min dvdd = 5 v 5% input low voltage, v inl 0.8 v max dvdd = 5 v 5% input current, i in 3 a max typical 10 na, v in = 0 v to dvdd input capacitance, c in 10 pf max
ade7758 rev. a | page 6 of 68 parameter specification unit test conditions/comments logic outputs dvdd = 5 v 5% irq , dout, and clkout irq is open-drain, 10 k? pull-up resistor output high voltage, v oh 4 v min i source = 5 ma output low voltage, v ol 0.4 v max i sink = 1 ma apcf and varcf output high voltage, v oh 4 v min i source = 8 ma output low voltage, v ol 1 v max i sink = 5 ma power supply for specified performance avdd 4.75 v min 5 v ? 5% 5.25 v max 5 v + 5% dvdd 4.75 v min 5 v ? 5% 5.25 v max 5 v + 5% ai dd 8 ma max typically 5 ma di dd 13 ma max typically 9 ma 1 see the section for a definition of the parameters. terminology 2 see the . typical perfor mance characteristics 3 see the section. analog inputs
ade7758 r e v. a | pa ge 7 o f 6 8 timing characteristics 1, 2 a v d d = d v dd = 5 v 5% , a g nd = d g nd = 0 v , o n -chi p r e f e r e n c e , clkin = 10 m h z xt al, t mi n to t max = ?40c t o +85c. table 2. parameter specification unit test condition s /comments write timing t 1 50 ns (min) cs falling edge to first sclk falling edge. t 2 50 ns ( min) sclk logic high pulse wid t h. t 3 50 ns ( min) sclk logic lo w pulse wid t h. t 4 10 ns (min) val i d data s e tup t ime before falling edge of sclk . t 5 5 ns (min) data hold time after sclk falling edge. t 6 900 ns (min) minimum time between the end of data byte tr ansfers. t 7 50 ns (min) minimum time between byte transfers during a serial wr ite. t 8 100 ns (min) cs hold time after sclk falling edge. read timing t 9 1 . 1 s ( m i n ) mini mum time b e tween rea d co mmand (i .e ., a wr ite to comm uni c ation re gister ) an d da ta rea d . t 10 50 ns (min) minimum time between data byte transfers dur i ng a multibyte read. t 11 3 30 ns (min) data access time after sclk rising ed ge followi ng a write to the communicatio n s register. t 12 4 100 ns (max) bus relinquish time after falling edge of sclk. 10 ns (min) t 13 4 100 ns (max) bus relin q uish time after rising ed ge of cs . 10 ns (min) 1 sa m p le t e st e d duri n g i n i t i a l relea s e a n d a f t e r a n y re de si g n or pr oces s ch a n g e t h a t m a y a ffect t h i s pa ra m e t e r. al l i n put si gn a l s a r e spec i f i e d wi t h t r = t f = 5 n s (10% t o 90% ) a n d t i m e d from a volt a g e lev e l o f 1.6 v. 2 see the timing diagrams in a n d a n d t h e s e c t i o n . f i g u r e 3 f i g u r e 4 a d e7758 serial interf a c e 3 mea s ure d with the loa d c i r c u i t i n a n d d e f i ne d as the time re quire d fo r the o u tput to cro s s 0.8 v or 2.4 v. f i g u re 2 4 derived fr om the measure d time tak e n by the data outputs to change 0.5 v when loade d wit h the circ uit in figure 2. the measu r e d numbe r is the n e x trapo l ate d back to remove the ef fec t s of charging or d i s c harging the 50 pf capacitor. this m e ans that the time quoted in the timing characteris tics is t h e true bus re l i nquis h time of t h e pa rt a n d i s i n de pen d en t of t h e bu s loa d i n g. 04443-0-002 200 ai ol 1.6ma i oh 2.1v t o output pin c l 50pf f i g u re 2. l o ad ci r c uit f o r tim i ng spec i f ic at ions
ade7758 r e v. a | pa ge 8 o f 6 8 04443-0-003 din s clk cs t 2 t 3 t 1 t 4 t 5 t 7 t 6 t 8 command byte most significant byte least significant byte 1a 6 a4 a5 a3 a2 a1 a0 db7 db0 db7 db0 t 7 fi g u r e 3 . s e r i a l w r i t e t i m i n g 04443-0-004 sclk cs t 1 t 10 t 13 0 a6 a4 a5 a3 a2 a1 a0 db0 db7 db0 db7 din dout t 11 t 12 command byte most significant byte least significant byte t 9 f i gur e 4 . s e ri al read t i m i ng
ade7758 r e v. a | pa ge 9 o f 6 8 absolute maximum ratings t a = 2 5 c , u n l e ss ot he r w i s e no t e d. table 3. avdd to ag nd C0.3 v to +7 v dvdd to dg nd C0.3 v to +7 v dvdd to a v dd C0.3 v to +0.3 v analog input voltage to agnd, iap, ian, ibp, ib n, icp, icn, vap, vbp, vcp, v n C6 v to +6 v reference input voltage to agn d C0.3 v to av dd + 0.3 v digital input voltage to dgnd C0.3 v to dv dd + 0.3 v digital output v o ltage to dgnd C0.3 v to dv dd + 0.3 v operating tem p erature range industrial C40c to +85c storage temperature range C65c to +150c junction tempe r ature 150c 24-lead soic, p o wer dissipation 88 mw ja thermal imp e dance 53c/w lead temperature, soldering vapor phase (60 sec) 215c infrared (15 sec) 220c s t r e s s es a b o v e t h os e list e d u nde r a b s o l u te m a xim u m r a t i n g s ma y ca us e p e r m a n e n t dama ge to t h e de vi ce. t h is is a st r e ss r a t i ng on ly ; f u n c t i on a l op e r at i o n of t h e d e v i c e a t t h e s e or an y o t h e r con d i t ions a b o v e t h os e list e d i n t h e op era t io nal s e c t ion s o f t h is sp e c if ic a t io n is n o t i m pli e d . e x p o sur e t o a b s o l u t e max i m u m r a t i ng co ndi t i on s fo r ex tende d p e r i o d s ma y a f fe c t de vice rel i a b i l i t y . esd caution esd (electrostatic discharge) sensitive device. ele c tros tatic charg e s as high as 4000 v readily accumulate on the human body and test eq uipment and can discharge wi thout detection. although this product features proprietary esd protection circu i try, permanent dama ge may occur on devices subjected to high energy electrostatic discharges. theref ore, prop er esd precautions a r e recommended to avoid perform a nce degradation or l o ss of functiona l ity.
ade7758 rev. a | page 10 of 68 pin conf iguration and fu nction descriptions 04443-0-011 ade7758 top view (not to scale) apcf 1 dout 24 dgnd 2 sclk 23 dvdd 3 din 22 avdd 4 cs 21 iap 5 clkout 20 ian 6 clkin 19 ibp 7 irq 18 ibn 8 varcf 17 icp 9 vap 16 icn 10 vbp 15 agnd 11 vcp 14 ref in/out 12 vn 13 f i gure 5. pin config ur ation ta ble 4. pi n f u nct i on d e s c ri pt i o ns pin no. mnemonic description 1 apcf active power calibration frequency (apc f) logic output. it provides active power information. this output is used for operational a n d calibr a t ion purpose s . t h e full-sc ale output freq uency can be sc aled by writing to the apcfnum and apcfden regist ers (see the active power freq u ency output section). 2 dgnd this provides the ground reference for the digital circ uitry in the ade7758, i.e., the multiplier, filters, and digital-to-freq u ency converter. because the digital return cu rrents in the ade77 58 are small, it is acceptable to connect this pi n to the analog ground plane of th e who l e syste m . however, hig h bus capa citan c e on the dout pin may result in noisy digital cu rrent which could affect performance. 3 dvdd digital power s u pply. t h is pin provides the su pply voltag e for the digital circuitry in the ade7 7 58. the supply voltage sh ould be maintained a t 5 v 5% for specifie d operatio n . t h is pin sh oul d be decoupled to dgnd with a 10 f capacitor in parallel wi th a ceramic 100 nf capacitor. 4 avdd analog power s u pply. this pin provides the su pply volt age for the analog cir c uitry in the ade7 758. the supply should be maint a ined at 5 v 5 % for specified opera tion. every effort should be made to minimize power supply ripp le an d noise at this pi n by the use of proper decoup li ng. t h e t y pical performance ch aracteristics graphs s h ow th e power sup p ly rejection p e rfor mance. t h is pi n should be d e co upled to agnd with a 10 f capacitor i n par a lle l with a ceramic 100 nf capacitor. 5, 6; 7, 8; 9, 10 iap, ian; ibp, ibn; icp, icn analog inputs for current channel. this channel is used with the current tr ansducer and is referenced in this document as the current chann e l. these inputs are fully differential voltage in puts with maximu m differential input signal le v e ls of 0.5 v, 0. 25 v, and 0.125 v, d e pending on the gain sele ctio ns of the internal pga (see the analog inpu ts sections). all inputs have internal esd protection circuitry, and in addition, an overvo ltage of 6 v can be s u stained on these inputs wit h out risk of per m anent damag e . 11 agnd this pin prov ides the ground reference for the analog circuitry in the ade7758, i.e., adcs, temperature sensor, and reference. this pin should be ti ed to the analog ground plan e or th e quietest ground reference in the system. this quiet ground refere nce shou ld be u s ed for all analog circuitry, for e x ample, antialiasing filters, current, and voltage transducers. in order to keep gr ound noise around the ade 7758 to a mi nimum, the quiet ground plane sh ould only be connected to the digital ground plane at on e point. it is acceptable to place the entire device on the analog gro u nd plane. 12 ref in /ou t this pin prov ides access to the o n -chip vo ltage r e ference. the o n -chip refere nc e has a nom i nal value of 2.5 v 8% and a typical temperature coefficient of 30 ppm/c. an extern al refer e nce source ma y also be connected at this pin. in either case, this pin should be decoupled to agn d with a 1 f ceramic c a pacitor. 13, 14, 15, 16 vn, vcp, vbp, vap analog inputs for the voltage channel. this cha nnel is used wit h the volt age transducer and is referenced as the voltage cha nnels i n this doc u ment. these inputs are single- e nded voltage inputs with the maximum signal level of 0.5 v with respec t to vn for spec ified operation. thes e inputs are voltage inputs with maximum input signal le vels of 0.5 v, 0.25 v, and 0. 125 v, depending on the gain selecti o ns of the internal pga (see the an alog inputs section). all inputs have internal esd protection circuitry, and in addition, an overvo ltage of 6 v can be s u stained on these inputs wit h out risk of per m anent damag e .
ade7758 rev. a | page 11 of 68 pin no. mnemonic description 17 varcf reactive power calibration frequency logic output. it gives reactive power or apparent power information depending on the setting of the vacf bit of the wavm ode register. this output is used for operational and calibration purposes. the full-scal e output frequency can be scaled by writing to the varcfnum and varcfden registers (see the reactive power frequency output section). 18 irq interrupt request output. this is an active low open- drain logic output. maskable interrupts include: active energy register at half level, apparent energy register at half level, and waveform sampling up to 26 ksps (see the ade7758 interrupts section). 19 clkin master clock for adcs and digital sign al processing. an external clock can be provided at this logic input. alternatively, a parallel resonant at crystal can be connected across cl kin and clkout to provide a clock source for the ade7758. the clock frequency for specifie d operation is 10 mhz. ceramic load capacitors of a few tens of picofarad should be used with the gate osci llator circuit. refer to the crystal manufacturers data sheet for the load capacitance requirements 20 clkout a crystal can be connected across this pin and clkin as previously described to provide a clock source for the ade7758. the clkout pin can drive one cmos load when ei ther an external clock is supplied at clkin or a crystal is being used. 21 cs chip select. part of the 4-wire serial interface. this active low logic input allows the ade7758 to share the serial bus with several other devices (see the ade7758 serial interface section). 22 din data input for the serial interface. da ta is shifted in at this pin on th e falling edge of sclk (see the ade7758 serial interface section). 23 sclk serial clock input for the synchronous se rial interface. all serial data transfers are synchronized to this clock (see the ade7758 serial interface section). the sclk has a schmidt-trigger input for use with a clock source which has a slow edge transition time, for example, opto-isolator outputs. 24 dout data output for the serial inte rface. data is shifted out at this pin on the rising edge of sclk. this logic output is normally in a high impedance state, unless it is driv ing data onto the serial da ta bus (see the ade7758 serial interface section).
ade7758 rev. a | page 12 of 68 terminology m e a s u r em ent e r ro r the er r o r as s o ci a t e d w i t h t h e e n erg y m e as ur e m en t made b y t h e ad e7758 is def i n e d b y t h e f o l l o w in g f o r m u l a % 100 C = energy true energy true ade7758 by registered energy error t measuremen p h as e err o r b e t w e e n c h a nne ls t h e h i gh - p as s f i l t e r a n d di gi tal in t e gra t o r i n tr o d u c e a s l i g h t phas e misma t ch b e tw e e n t h e c u r r en t a nd t h e v o l t a g e chann e l . the al l- dig i t a l desig n en s u r e s t h a t t h e phas e ma t c hin g b e twe e n t h e c u r r en t channe ls an d v o l t ag e cha nne ls i n a l l t h r e e phas es i s wi thin 0.1 o v er a ra n g e o f 45 h z t o 65 h z and 0.2 o v er a ra n g e o f 40 h z to 1 kh z. this in t e r n a l phas e mi sma t ch ca n b e co m b i n e d wi t h t h e ext e r n al phas e er r o r (f r o m c u r r en t s e ns o r o r co m p o n en t t o l e ra n c e ) a n d cali b r a t ed wi th t h e ph a s e cali b r a t i o n re g i ste r s . p o wer s u pply rej e c t i o n this q u a n t i f i es th e ad e7758 meas ur emen t er r o r as a p e r c en t a g e o f r e adi n g w h e n t h e p o w e r s u p p lie s a r e va r i e d . f o r t h e ac ps r m e a s ur em e n t, a r e a d in g a t n o m i na l su p p lies (5 v) i s t a k e n. a s e cond r e adin g is ob t a i n e d wi t h t h e s a m e in p u t sig n a l lev e l s w h en an ac sig n al (175 mv r m s / 100 h z ) is in tr o d uce d o n t o t h e s u p p lies. an y er r o r in tr o d uce d b y this ac sig n al is exp r es s e d as a p e r c en t a g e o f r e adin g s e e t h e m e as ur emen t er r o r def i ni t i o n . f o r t h e dc psr m e as ur e m en t, a r e adin g a t n o minal s u p p lies (5 v ) i s tak e n . a seco n d r e ad in g i s o b ta in ed w i th t h e sa m e in p u t sig n al le ve ls w h en t h e p o w e r s u p p lies a r e va r i e d 5%. a n y er r o r in t r o d uce d is a g a i n exp r es s e d as a p e r c en t a g e o f t h e r e adin g . ad c off s et err o r this r e fers t o t h e dc o f fs et as s o c i a t e d w i t h t h e analog in p u ts t o th e a d c s . i t m e a n s th a t w i t h t h e a n alog i n p u ts co n n ec t e d t o a g nd t h e ad cs s t i l l s e e a dc a n alog in p u t sig n al . th e ma g n i t u d e o f t h e o f fs et dep e n d s o n t h e ga i n an d in p u t ra n g e s e le c t ion (s e e t h e t y p i ca l p e r f o r ma n c e c h a r ac t e r i st ics s e c t ion). h o w e v e r , w h en hp fs a r e sw i t che d o n , t h e o f fs et is r e m o v e d f r o m t h e c u r r en t cha n n e ls and t h e p o w e r calc u l a t io n is n o t af fe c t e d b y t h i s of f s e t . ga in e r r o r the ga in er r o r in t h e ad cs o f t h e ad e7758 is def i n e d as t h e dif f er en ce b e twe e n t h e m e as ur e d ad c o u t p u t co de (min us t h e o f fs et) a n d t h e i d e a l o u t p ut co de (s e e t h e c u r r e n t c h a n ne l a d c a nd v o l t a g e c h a nnel a d c s e c t io n s ). t h e dif f er en c e is exp r es s e d as a p e r c en t a g e o f t h e ide a l co de . ga in e r r o r m a t c h the ga i n er r o r ma t c h is def i n e d as t h e ga i n er r o r (min us t h e of f s e t ) o b t a i n e d w h e n s w itch i n g b e t w e e n a g a i n of 1 , 2 , or 4 . i t i s exp r es s e d as a p e r c en t a g e o f t h e o u t p u t ad c c o de ob t a in e d un der a ga in o f 1.
ade7758 rev. a | page 13 of 68 typical perf orm ance cha r acte ristics 0.5 ? 0.5 ? 0.4 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.3 0.4 0.01 0.1 1 1 0 100 04443-0-060 percent full-scale current (%) p e rce nt e rror (%) +25 c pf = 1 +85 c ?4 0 c f i gure 6 . a c ti v e ener gy err o r a s a p e r c enta ge o f rea d i n g (g a i n = +1 ) o v er t e m p er ature w i th i n tern a l r e fe r e nce a n d integ r ator o ff 0.3 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.01 0.1 1 1 0 100 04443-0-061 percent full-scale current (%) p e rce nt e rror (%) pf = +1, +25 c pf = +0.5, +25 c pf = ? 0.5, +25 c pf = +0.5, +85 c pf = +0.5, ?40 c f i gure 7 . a c ti v e ener gy err o r a s a p e r c enta ge o f rea d i n g (g a i n = +1 ) o v er p o we r f a c t or w i t h i n tern a l r e f e r e nce a n d integ r at or o f f 0.3 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.01 0.1 1 1 0 100 04443-0-062 percent full-scale current (%) p e rce nt e rror (%) gain = +2 gain = +4 pf = 1 gain = +1 f i gure 8 . a c ti v e ener gy err o r a s a p e r c e n t a g e of r e ad ing over g a in w i t h intern a l r e f e r e nce and in teg r at or o f f 0.20 ?0.20 ?0.15 ?0.10 ?0.05 0 0.05 0.10 0.15 0.01 0.1 1 1 0 100 04443-0-063 percent full-scale current (%) p e rce nt e rror (%) pf = ? 0.5, +25 c pf = +0.5, +25 c pf = +0.5, ?40 c pf = +0.5, +85 c f i gure 9 . a c ti v e ener gy err o r a s a p e r c enta ge o f rea d i n g (g a i n = +1 ) o v er p o we r f a c t or w i t h e x tern al r e f e renc e and in teg r at or o f f 0.5 0.6 ? 0.2 ? 0.3 ? 0.4 ? 0.1 0 0.1 0.2 0.3 0.4 45 47 49 51 53 55 57 59 61 63 65 04443-0-065 line frequency (hz) p e rce nt e rror (%) w i th r espec t to 55h z pf = 1 pf = 0.5 f i g u re 10. ac t i ve e n er g y e rror as a p e r cent a g e of r e ading (g ain = +1) o v er f r equ e nc y w i t h int e rn al r e f e renc e an d integ r at or o f f 0.08 0.10 ?0.06 ?0.08 ?0.10 ?0.04 ?0.2 ?0.0 0.02 0.04 0.06 0.01 0.1 1 1 0 100 04443-0-066 percent full-scale current (%) p e rce nt e rror (%) w i th r espec t to 5v; 3a v dd = 5v v dd = 5.25v v dd = 4.75v pf = 1 f i g u re 11. ac t i ve e n er g y e rror as a p e r cent a g e of r e ading (g ain = +1) o v er p o we r su p p ly w i t h intern a l r e f e r e nce and in teg r at or o f f
ade7758 rev. a | page 14 of 68 0.20 0.25 ?0.15 ?0.20 ?0.25 ?0.10 ?0.05 0 0.05 0.10 0.15 0.01 0.1 1 1 0 100 04443-0-067 percent full-scale current (%) p e r ce nt e rror (%) phase a phase b phase c all phases pf = 1 f i g u re 12. a p cf e r ror as a p e r c e n t a g e of r e ad ing (g ain = +1) wi th internal referenc e a n d int e g r a t or o ff 0.4 ? 0.4 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.3 0.01 0.1 1 1 0 100 pf = 0, +25 c pf = 0, +85 c pf = 0, ?40 c 04443-0-068 percent full-scale current (%) p e rce nt e r ror (%) f i g u re 13. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g (g ain = +1) o v e r t e m p er ature w i th i n tern a l r e fe r e nce a n d integ r ator o ff 0.8 ? 0.8 ? 0.6 ? 0.4 ? 0.2 0 0.2 0.4 0.6 0.01 0.1 1 1 0 100 04443-0-069 percent full-scale current (%) p e rce nt e rror (%) pf = 0, +25 c pf = ? 0.866, +25 c pf = +0.866, +25 c pf = +0.866, +85 c pf = +0.866, ?40 c f i g u re 14. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g (g ain = +1) o v e r p o we r f a c t or w i t h i n tern a l r e f e r e nce a n d integ r at or o f f 0.3 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.01 0.1 1 1 0 100 04443-0-070 percent full-scale current (%) p e r ce nt e rror (%) pf = 0, +25 c pf = 0, +85 c pf = 0, ?40 c f i g u re 15. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g (g ain = +1) o v e r t e m p er at ure wit h e x tern al r e f e renc e and in teg r at or o f f 0.3 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.01 0.1 1 1 0 100 04443-0-071 percent full-scale current (%) p e rce nt e r ror (%) pf = 0, +25 c pf = ? 0.866, +25 c pf = +0.866, +25 c pf = +0.866, +85 c pf = +0.866, ?40 c f i g u re 16. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g (g ain = +1) o v e r p o we r f a c t or w i t h e x tern al r e f e renc e and in teg r at or o f f 0.8 ?0.8 ?0.6 ?0.4 ?0.2 0 0.2 0.4 0.6 45 47 49 51 53 55 57 59 61 63 65 04443-0-072 line frequency (hz) p e rce nt e rror (%) w i th r espec t to 55h z pf = 0 pf = 0.866 f i g u re 17. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g (g ain = +1) o v e r f r equ e nc y w i t h int e rn al r e f e renc e an d integ r at or o f f
ade7758 rev. a | page 15 of 68 0.10 ?0.10 ?0.08 ?0.06 ?0.04 ?0.02 0 0.02 0.04 0.06 0.08 0.01 0.1 1 1 0 100 04443-0-073 percent full-scale current (%) p e rce nt e rror (%) w i th r espec t to 5v; 3a 5v 5.25v 4.75v f i g u re 18. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g (g ain = +1) o v e r sup p l y wi th int e rna l r e ferenc e a n d int e gr at or o ff 0.3 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.01 0.1 1 1 0 100 04443-0-074 percent full-scale current (%) p e rce nt e rror (%) gain = +1 gain = +2 gain = +4 pf = 0 f i g u re 19. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g o v er g a in w i t h intern a l r e f e r e nce and in teg r at or o f f 0.4 ? 0.4 ? 0.2 ? 0.3 ? 0.1 0 0.1 0.2 0.3 0.01 0.1 1 1 0 100 04443-0-075 percent full-scale current (%) p e rce nt e rror (%) phase a all phases phase c phase b pf = 1 f i g u re 20. v a r c f e r r o r as a p e rc ent a g e of r e ading (g ai n = +1) wi th internal referenc e a n d int e g r a t or o ff 0.3 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.01 0.1 1 1 0 100 04443-0-076 percent full-scale current (%) p e rce nt e rror (%) +25 c +85 c ?4 0 c f i g u re 21. ac t i ve e n er g y e rror as a p e r cent a g e of r e ading (g ain = +4) o v er t e m p er ature w i th i n tern a l r e fe r e nce a n d integ r ator o n 0.5 0.4 ? 0.5 ? 0.4 ? 0.2 ? 0.3 ? 0.1 0 0.1 0.2 0.3 0.01 0.1 1 1 0 100 04443-0-077 percent full-scale current (%) p e rce nt e rror (%) pf = +1, +25 c pf = ? 0.5, +25 c pf = +0.5, +25 c pf = +0.5, +85 c pf = +0.5, ?40 c f i g u re 22. ac t i ve e n er g y e rror as a p e r cent a g e of r e ading (g ain = +4) o v er p o we r f a c t or w i t h i n tern a l r e f e r e nce a n d integ r at or o n 0.8 ? 0.8 ? 0.4 ? 0.6 ? 0.2 0 0.2 0.4 0.6 0.01 0.1 1 1 0 100 04443-0-078 percent full-scale current (%) p e rce nt e rror (%) pf = 0, +25 c pf = +0.866, +25 c pf = ? 0.866, +25 c pf = ? 0.866, +85 c pf = ? 0.866, ?40 c f i g u re 23. ac t i ve e n er g y e rror as a p e r cent a g e of r e ading (g ain = +4) o v er p o we r f a c t or w i t h i n tern a l r e f e r e nce a n d integ r at or o n
ade7758 rev. a | page 16 of 68 0.4 ? 0.5 ? 0.4 ? 0.2 ? 0.3 ? 0.1 0 0.1 0.2 0.3 0.01 0.1 1 1 0 100 04443-0-079 percent full-scale current (%) p e rce nt e rror (%) +25 c +85 c ?40 c pf = 0 f i g u re 24. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g (g ain = +4) o v e r t e m p er ature w i th i n tern a l r e fe r e nce a n d integ r ator o n 0.5 0.4 ? 0.5 ? 0.4 ? 0.2 ? 0.3 ? 0.1 0 0.1 0.2 0.3 45 47 49 51 53 55 57 59 61 63 65 04443-0-080 line frequency (hz) p e rce nt e rror (%) pf = 1 pf = 0.5 f i g u re 25. ac t i ve e n er g y e rror as a p e rc ent a g e of r e adi n g (g ain = +4) o v er f r equ e nc y w i t h int e rn al r e f e renc e an d integ r at or o n 1.2 1.0 ? 0.8 ? 0.6 ? 0.2 ? 0.4 0 0.2 0.4 0.6 0.8 45 47 49 51 53 55 57 59 61 63 65 04443-0-081 line frequency (hz) p e rce nt e rror (%) pf = 0.866 pf = 0 f i g u re 26. r e ac t i ve e n er g y e rror as a p e r cent a g e of r e adi n g (g ain = +4) o v e r f r equ e nc y w i t h int e rn al r e f e renc e an d integ r at or o n 0.8 0.6 ? 1.2 ? 1.0 ? 0.6 ? 0.8 ? 0.4 ? 0.2 0 0.2 0.4 0.01 0.1 1 1 0 100 pf = 0.5 04443-0-082 percent full-scale current (%) p e rce nt e rror (%) pf = 1 f i g u re 27. ir m s e rror as a p e r c e n t a g e of r e ad ing (g ain = +1) wi th internal referenc e a n d int e g r a t or o ff 0.8 0.6 ? 1.0 ? 0.6 ? 0.8 ? 0.4 ? 0.2 0 0.2 0.4 0.1 1 1 0 100 pf = +1 pf = ? 0.5 04443-0-083 percent full-scale current (%) p e rce nt e rror (%) f i g u re 28. ir m s e rror as a p e r c e n t a g e of r e ad ing (g ain = +4) wi th internal referenc e a n d int e g r a t or o n 0.4 ? 0.4 ? 0.3 ? 0.2 ? 0.1 0 0.1 0.2 0.3 1 1 0 100 04443-0-084 voltage (v) p e rce nt e rror (%) f i gure 2 9 . vrms erro r a s a p e r c enta ge o f rea d i n g ( g a i n = +1 ) wi th internal referenc e
ade7758 rev. a | page 17 of 68 1.5 ? 1.5 ? 1.0 ? 0.5 0 0.5 1.0 0.01 1 1 0 0.1 100 +25 c +85 c ?4 0 c 04443-0-085 percent full-scale current (%) p e rce nt e rror (%) f i g u re 30. a p pa r e n t e n er g y e rror as a p e r cent a g e of r e ad ing (g a i n = + 1 ) o v e r t e m p er ature w i th i n tern a l r e fe r e nce a n d integ r ator o ff 04443-0-088 ? 4 ? 2 0 246 8 1 0 1 2 18 15 12 9 6 3 0 ch 1 pha offset (mv) hits mean: 5.55393 sd: 3.2985 f i g u re 31. phas e a chann e l 1 o f f s et d i s t ribut i on 04443-0-089 ? 2 024 68 1 0 1 2 18 21 15 12 9 6 3 0 ch 1 phb offset (mv) hits mean: 6.5149 sd: 2.816 f i g u re 32. phas e b chann e l 1 o f f s et d i s t ribut i on 04443-0-090 2468 1 0 1 4 12 12 10 8 6 4 2 0 ch 1 phc offset (mv) hits mean: 6.69333 sd: 2.70443 f i g u re 33. phas e c chann e l 1 o f f s et d i s t ribut i on
ade7758 rev. a | page 18 of 68 ref in/out 33nf 1k ? 100nf 33nf 1k ? 10 f v dd vn ian ibp ibn icp icn vap avdd dvdd vbp vcp agnd dgnd dout sclk apcf clkout clkin cs din ir q 10mhz 22pf 22pf ps2501-1 13 11 2 1 to freq. counter 14 23 20 iap rb same as i ap , i an 9 8 7 10 16 15 14 100nf 10 f 33nf 1k ? 1m ? 220v 33nf 1k ? 825 ? i to spi bus only used for calibration 3 4 19 5 6 24 23 21 22 18 12 same as i ap , i an same as v ap same as v ap ade7758 current transformer 17 varcf ct turn ratio 1800:1 channel 2 gain = +1 channel 1 gain r b 11 0 ? 25 ? 4 2.5 ? 8 1.25 ? 04443-0-086 f i gure 3 4 . t e st c i rcui t fo r int e g r at or o ff ref in/out 33nf 1k ? 33nf 1k ? 33nf 1k ? 33nf 1k ? 100nf 10 f v dd vn ian ibp ibn icp icn vap avdd dvdd vbp vcp agnd dgnd dout sclk apcf clkout clkin cs din ir q 10mhz 22pf 22pf ps2501-1 13 11 2 1 to freq. counter 14 23 20 iap same as i ap , i an 9 8 7 10 16 15 14 100nf 10 f 33nf 1k ? 1m ? 220v 33nf 1k ? 825 ? to spi bus only used for calibration 3 4 19 5 6 24 23 21 22 18 12 same as i ap , i an same as v ap same as v ap ade7758 i di/dt sensor 17 varcf channel 1 gain = +8 channel 2 gain = +1 04443-0-087 f i gure 35. t e s t c i rc uit for integ r a t o r o n
ade7758 rev. a | page 19 of 68 theory of operation antialiasing fil t er the n e e d fo r t h i s f i l t er is t h a t i t p r e v en ts a l iasing. a l ias i n g is an a r tifac t o f al l s a m p le d sys t e m s. i n p u t sig n als wi th f r e q uen c y co m p on en ts hig h er than half t h e ad c s a m p ling ra t e dis t o r t t h e s a m p le d sig n al a t a f r e q ue n c y b e lo w half t h e s a m p lin g r a t e . this w i l l h a pp e n w i t h a l l a d c s , re g a rd l e ss of t h e ar ch ite c tu re. t h e co m b in a t io n o f t h e hig h s a m p li n g ra t e - ? ad c us e d i n t h e ad e7758 wi th t h e r e la ti ve l y lo w ba ndwid th o f t h e en erg y met e r al lo ws a v e r y sim p le lo w-p a s s f i l t er (lp f ) t o b e us ed as a n a n t i al iasi n g f i l t e r . a sim p le r c f i l t er (sin g l e p o le) wi t h a co r n er f r e q uen c y o f 10 khz p r o d uces an a t t e n u a t ion o f a p p r o x ima t ely 40 db a t 833 kh z. this is usual l y s u f f i cien t t o e l imina t e t h e ef fe c t s o f aliasing. analog inputs the ad e7758 has a t o tal o f six a n alog in p u ts divided in t o tw o cha nnels: c u r r en t an d vol t a g e. the c u r r en t channel co n s ists o f t h r e e p a irs o f f u l l y dif f er en t i al vol t a g e i n p u t s : i a p an d i a n, i b p a nd ibn, an d icp a nd i c n. t h es e f u l l y dif f er en t i a l vol t a g e in p u t p a irs ha v e a maxi m u m dif f er en t i al sig n al o f 0.5 v . the c u r r en t cha n ne l has a p r og ra mma b l e ga i n a m plif ier (pga) w i t h p o s s i b le gain s e l e c t io n o f 1, 2, o r 4. i n addi tio n t o th e pga, t h e c u r r en t c h a n ne ls als o ha v e a f u l l -s c a le in p u t ra ng e s e le c t ion f o r t h e ad c. th e ad c a n alog i n p u t ra n g e s e le c t io n is als o made usin g the ga in reg i s t er (s ee f i gu r e 38). a s m e n t io n e d p r evio u s l y , t h e maxi m u m dif f er en t i al in pu t v o l t a g e is 0.5 v . h o we v e r , b y usin g bi t 3 an d bi t 4 i n t h e ga i n r e g i s t er , t h e maxim u m ad c in p u t v o l t a g e can b e s e t t o 0.5 v , 0.25 v , o r 0.125 v o n t h e c u r r en t cha n ne ls. this is ach i e v e d b y ad j u st i n g t h e ad c re f e re nc e ( s e e t h e r e f e re n c e c i rc u i t s e c t i o n ) . f i gur e 36 sh o w s t h e maxi m u m s i g n al le ve ls o n t h e c u r r en t cha nnel i n p u ts. the max i m u m co mm on- m o d e sig n a l is 25 mv as sh o w n in f i gur e 36 . differential input v 1 + v 2 = 500mv max peak + 500m v v cm v 1 iap, ibp, or icp v cm ?500mv common-mode 25mv max v 1 + v 2 v 2 ian, ibn, or icn 04443- 0- 108 f i g u re 36. m a x i mu m s i g n a l l e vels, cu rr e n t cha nne ls, g a i n = 1 the v o l t a g e channe l has t h r e e sin g le -e n d e d v o l t a g e i n p u ts: v a p , vb p , and v c p . th es e sing le-en d e d v o l t a g e in p u ts ha v e a max i m u m i n p u t vol t a g e o f 0.5 v w i t h r e sp e c t to vn. b o t h t h e c u r r e n t a n d volt age ch an n e l h a v e a p g a w i t h p o ss ibl e g a i n s e lec t ion s o f 1, 2, o r 4. th e s a me ga in is a p p l ie d t o al l the in p u ts of e a ch chan nel. fi g u r e 3 7 s h ow s t h e m a x i m u m s i g n a l l e v e l s o n t h e v o lt a g e cha nnel i n p u ts. the max i m u m co mm on- m o d e sig n a l is 25 mv as sh o w n in f i gur e 36 . single-ended input 500mv max peak +500mv agnd v cm v2 vap, vbp, or vcp v cm ? 500mv common-mode 25mv max v n v2 04443-0-109 f i g u re 37. m a x i mu m s i g n a l l e vels, v o lt ag e c h an nels, g a in = 1 the ga i n s e le c t i o n s a r e made b y wr i t in g t o t h e g a in r e g i st er . bi t 0 t o bi t 1 s e l e c t t h e ga i n fo r t h e pga in t h e f u l l y dif f er en t i al c u r r en t cha n ne l. the ga i n s e le c t io n fo r t h e pg a in t h e s i n g le - ende d vol t a g e cha nnel is ma de v i a bi t 5 to bi t 6 . f i gur e 38 s h o w s h o w a g a in s e l e cti o n f o r th e cu rr e n t c h a n n e l i s m a de usin g the ga in reg i s t er . 04443- 0- 012 iap, ibp, icp ian, ibn, icn v in k v in gain[7:0] gain (k) selection f i gure 38. pg a in current cha nne l f i gur e 39 sh o w s h o w t h e ga in s e t t in gs in pga 1 (c ur r e n t cha nnel) an d p g a 2 (vol t a ge cha nnel) a r e s e le c t e d b y va r i o u s b i ts in t h e ga i n r e g i s t er . 04443-a-013 gain register* current and voltage channel pga control 7 6 5 4 3 2 1 0 0 0 0 0 0 0 0 0 address: 0x23 reserved *register contents show power-on defaults pga 2 gain select 00 = 1 01 = 2 10 = 4 integrator enabl e 0 = disable 1 = enabl e pga 1 gain select 00 = 1 01 = 2 10 = 4 current input full-scale select 00 = 0.5v 01 = 0.25v 10 = 0.125v f i gure 39. ade 7 7 5 8 a n a l og g a in reg i ster bi t 7 o f t h e ga in r e g i s t er is us e d t o ena b le t h e di g i t a l i n teg r a t o r i n t h e curr en t sign al pa th . s e t t in g th i s b i t w i ll acti v a t e t h e d i g i t a l in teg r a t o r (s e e t h e di /d t c u r r en t s e n s o r an d di g i t a l i n teg r a t o r secti o n ) .
ade7758 rev. a | page 20 of 68 current channel adc f i gur e 41 sh o w s th e ad c and sig n al p r o c es sin g p a th fo r th e in p u t i a o f t h e c u r r en t cha n ne ls (s a m e fo r ib a nd i c ). i n wa v e fo r m s a m p lin g m o de , t h e ad c o u t p u t s a r e sig n e d tw os co m p lem e n t 24-b i t da t a -w o r ds a t a maxim u m o f 26.0 ks ps (t h o us an d s a m p les p e r s e co nd). w i t h t h e sp e c if ie d f u l l -s c a le a n alog in p u t sig n al o f 0.5 v , t h e ad c p r o d uces i t s max i m u m o u t p u t co de val u e (s ee f i gur e 4 1 ). this dia g ra m sh o w s a f u l l - s c ale v o l t a g e sig n al b e in g a p plie d t o t h e dif f er en t i al in p u ts i a p a nd i a n. the ad c o u t p u t s w ings betw een 0xd7ae14 (?2,642,412) a nd 0x2851ec (+2,642,412). curr ent w a ve form g a in re gisters ther e is a m u l t i p lier in t h e s i g n al p a t h in t h e c u r r en t cha n n e l for e a ch phas e. the c u r r e n t w a ve for m c a n b e c h ange d b y 5 0 % b y wr i t ing a twos co m p lem e n t n u m b er t o t h e 1 2 -b i t sig n ed c u r r en t wa v e f o r m ga in reg i s t ers (ai g ain[11:0] , b i gai n [11:0], a nd ci g a in[1 1:0]). f o r exa m p l e , if 0x7ff is wr i t t e n t o t h os e r e g i s t ers, t h e ad c o u t p u t is s c aled u p b y +50%. on t h e o t h e r ha nd , wr i t in g 0 x 800 s c aled b y t h e o u t p u t C50 % . the exp r es sio n b e lo w de s c r i b e s ma t h ema t ic al l y t h e f u n c t i o n o f t h e c u r r en t wa v e fo r m ga i n r e g i st ers. ? ? ? ? ? ? + = 12 2 1 register gain current of content output adc waveform current cha n g i n g t h e c o n t en t o f ai gain[11:0], b i gain[11:0], o r ci gai n [11:0] a f f e c t s al l calc u l a t io n s bas e d on i t s c u r r en t, i . e., i t a f fe c t s t h e phas e s ac t i ve /r e a c t i v e/a p p a r e n t e n erg y as w e l l as i t s cu rr e n t rm s c a lcul a t i o n . i n a d d i ti o n , w a v e f o rm sa m p l e s a r e al so s c ale d acco r d ing l y . current channel s a mpling the w a v e fo r m s a m p les o f t h e c u r r en t cha n n e l ca n b e r o u t e d to t h e wfo r m r e g i s t er a t f i xe d s a m p lin g r a t e s b y s e t t in g t h e w a v s el[2:0] b i t in t h e w a vm o d e r e g i s t er t o 000 (b ina r y). the phas e in w h ich t h e s a m p le s a r e r o u t e d is s e t b y s e t t in g t h e p h s e l[1:0] b i ts in t h e w a vmo d e r e g i s t er . en erg y calc u l a t ion r e ma in s un in t e r r u p t e d d u r i n g wa v e fo r m s a m p lin g . w h en in wa v e fo r m s a m p le m o de , on e o f fo ur o u t p ut s a m p le ra t e s ma y be chos en b y usin g b i t 5 an d bi t 6 o f th e w a vm o d e r e g i s t er (d tr t[ 1:0]). th e o u t p u t s a m p le ra t e ma y b e 26.0 ks ps, 13.0 ks ps, 6.5 ks ps, o r 3.3 ks ps (s ee t a b l e 16). b y s e t t in g t h e w s mp b i t i n t h e i n ter r u p t ma sk r e g i st er t o l o g i c 1, t h e i n t e r r upt re qu e s t output ir q g o es ac ti v e lo w when a s a m p le is a v a i la b l e . t h e t i m i n g i s s h ow n i n fi g u r e 4 0 . t h e 2 4 - bit w a v e f o r m s a m p l e s a r e t r a n sfer r e d f r o m t h e ad e77 58 o n e b y t e (8- b i t s) a t a t i me , wi t h t h e m o st si g n if ica n t b y t e shif t e d ou t f i rst. 04443-0-015 read from waveform 0 sgn current channel data ?24 bits 12hex sclk din dout irq f i gur e 4 0 . c u rr e n t ch a n ne l w a v e fo rm s a m p li n g the i n t e r r u p t r e q u es t o u t p u t ir q s t a y s lo w un t i l t h e in t e r r u p t r o u t ine r e ads t h e r e s e t s t a t us r e g i s t er (s ee ad e 7758 i n t e r r u p ts ) . 04443-a - 014 digital integrator* gain[7] adc reference aigain[11:0] active and reactive power calculation waveform sample register current rms (irms) calculation iap ian pga1 v in gain[4:3] 2.42v, 1.21v, 0.6v gain[1:0] 1, 2, 4 analog input range v in 0v 0.5v/gain 0.25v/gain 0.125v/gain adc output word range channel 1 (current waveform) data range 0xd7ae14 0x000000 0x2851ec 50hz channel 1 (current waveform) data range after integrator (50hz and aigain[11:0] = 0x000) 0xcb2e48 0x000000 0x34d1b8 60hz channel 1 (current waveform) data range after integrator (60hz and aigain[11:0] = 0x000) 0xd4176d 0x000000 0x2be893 hpf f i gure 4 1 . c u rr ent cha n n e l s i gn a l p a t h
ade7758 rev. a | page 21 of 68 di/dt current sens or and digi ta l integra t o r the di/d t s e n s or det e c t s c h an g e s in t h e ma g n e t ic f i e l d c a us e d b y t h e ac c u r r en t. f i gur e 42 sh o w s t h e p r i n c i ple o f a di / d t c u r r en t se n s o r . 04443-0-017 magnetic field created by current (directly proportional to current) + emf (electromotive force) ? induced by changes in magnetic flux density (di/dt) f i g u re 42. p r inc i pl e of a d i /dt cur r ent s e ns or the f l ux den s i t y o f a ma g n et ic f i eld ind u ce d b y a c u r r en t is dir e c t l y p r o p o r t i o n al t o t h e mag n i t u d e o f t h e c u r r en t. th e c han g e s in t h e ma g n et ic f l ux den s i t y p a s s ing t h r o ug h a cond uc to r l o o p g e n e ra t e a n e l ectr o m o t i v e f o r c e (emf) be t w een t h e t w o e n ds o f t h e l o op . the emf is a vol t a g e s i g n a l t h a t i s p r o p o r t i ona l t o t h e di / d t o f t h e c u r r en t. the v o l t a g e o u t p u t f r o m t h e di/ d t cu rr e n t se n s o r i s d e t e rmin ed b y th e m u t u al in d u cta n ce bet w een t h e c u r r en t ca r r y i n g cond uc to r a nd t h e di/ d t s e n s o r . the c u r r en t sig n al n e e d s t o b e r e co v e r e d f r o m t h e di /d t sig n al b e fo r e i t can b e us e d . an in t e g r a t o r is t h er efo r e n e ces s a r y t o r e s t o r e th e s i g n al t o i t s o r ig inal f o r m . th e ad e 7758 has a b u i l t- i n d i gi tal in t e gra t o r t o r e c o v e r th e cu rr e n t s i gn al f r o m th e d i /d t s e ns or . t h e d i g i t a l i n te g r ator on c h an n e l 1 i s s w itc h e d o n b y defa u l t w h en t h e ad e7758 is p o w e r e d u p . s e t t in g t h e ms b o f t h e gai n [7:0] r e g i s t er t u r n s o n t h e in t e g r a t o r . f i gur e 43 t o f i gur e 46 sh o w t h e ma g n i t ude and phas e r e s p on s e o f t h e dig i t a l in teg r a t o r . 04443-0-091 10 100 1k 10k 20 ?50 ?40 ?30 ?20 ?10 0 10 frequency (hz) gain ( d b) f i gur e 4 3 . c o m b ined ga in re sp onse o f the d i g i t a l in teg r at or a n d phas e co mpe n s a to r 04443-0-092 10 100 1k 10k 80 91 90 89 88 87 86 85 84 83 82 81 frequency (hz) ph a se ( d egrees) f i g u re 44. co mbi n e d p h as e r e s p ons e of t h e d i g i t a l in teg r at or a n d phas e co mpe n s a to r 04443-0-093 40 70 65 60 55 50 45 5 ?1 0 1 2 3 4 frequency (hz) magnitude (db) f i gur e 4 5 . c o m b ined ga in re sp onse o f the d i g i t a l in teg r at or a n d phas e co mpe n s a to r ( 40 h z to 7 0 h z ) 04443-0-094 40 70 65 60 55 50 45 89.80 90.10 90.05 90.00 89.95 89.90 89.85 frequency (hz) ph a se ( d egrees) f i g u re 46. co mbi n e d p h as e r e s p ons e of t h e d i g i t a l in teg r at or a n d phas e co mpe n s a to r ( 40 h z to 7 0 h z )
ade7758 rev. a | page 22 of 68 n o te t h a t t h e i n te g r a t or h a s a ? 2 0 db / d e c a t te n u a t i o n a n d a p p r o x im a t e l y ?90 phas e sh if t . w h e n com b i n e d wi t h a di /d t s e n s o r , t h e r e s u l t i n g m a g n i t u d e a n d phas e r e spo n s e sh o u ld b e a f l a t g a i n o ver t h e f r e q u e nc y b a nd of i n tere st . h o we ve r , t h e di / d t s e n s o r has a 20 d b /de c ga in ass o cia t e d wi t h i t a n d gen e ra t e s s i g n if i c an t hi g h f r e q ue nc y noi s e. a more ef fe c t ive an t i a l i a s i ng f i l t er i s n eed ed t o a v o i d n o i s e d u e t o a l i a s i n g (see th e t h e o r y of ope r a t i o n s e c t i o n ) . w h en t h e dig i t a l in teg r a t o r is s w i t ch ed o f f , t h e ad e7758 ca n b e us ed dir e c t l y wi th a con v en tio n al c u r r en t s e n s or , s u c h as a c u r r en t t r a n sfo r m e r (c t) o r a lo w r e sist an ce c u r r en t sh u n t. peak curr ent de tect ion the ad e7758 c a n b e p r og ra mm e d t o r e co r d t h e p e a k o f the cu rr e n t wa v e f o rm a n d p r o d u c e a n in t e rr u p t i f th e cu rr e n t exce e d s a p r es et limi t. peak c u rr ent det e ction usi n g the peak r e gister the p e ak abs o l u t e val u e o f t h e c u r r en t w a v e fo r m wi t h i n a f i xe d n u m b er o f half-li n e c y cles is s t o r e d i n t h e i p eak re g i ste r . f i g u re 4 7 i l lu st r a te s t h e t i m i ng b e h a v i or of t h e peak c u rr e n t det e cti o n . 04443-0-022 l2 l1 content of ipeak[7:0] 00 l1 l2 l1 no. of half line cycles specified by linecyc[15:0] register current waveform (phase selected by peaksel[2:0] in mmode register) f i gure 4 7 . p e a k c u rr ent detect io n using the ip eak re gi ster n o te t h a t t h e con t e n t o f t h e ip e a k reg i s t er is e q uiva le n t t o bi t 1 4 t o bi t 21 o f t h e c u r r en t w a v e fo r m s a m p le. a t f u l l -s ca l e a n a l og in p u t, t h e c u r r en t wa v e f o r m s a m p le is 0x2851ec . th e ip e a k a t f u l l -s c a le i n pu t is t h er efo r e exp e c t e d t o b e 0 x a1. i n ad di ti o n , m u l t i p le p h a s e s ca n b e a c ti v a t e d f o r th e p e ak de te c t i o n s i m u lt ane o u sly b y s e tt i n g m u lt i p l e b i t s to l o g i c h i g h a m o n g t h e p e a k s e l[2:4] b i t s i n t h e mmo d e r e g i s t er . th es e b i ts s e le c t t h e phas e fo r b o t h v o l t a g e and c u r r en t p e ak m e as ure- m e n t s. n o t e tha t if m o r e t h a n on e b i t is s e t, t h e vp eak an d ip eak r e g i st ers ca n h o ld v a l u es f r o m tw o dif f er en t phas es, t h a t is, t h e v o l t a g e and c u r r en t p e ak a r e indep e n d e n t l y p r o c es s e d (s e e t h e p e a k c u r r en t d e t e c t ion s e c t ion). n o t e t h a t t h e n u m b er o f half-l i n e c y cles is b a s e d o n co u n t i n g t h e zer o cr os sing o f t h e v o l t a g e cha nne l . th e z x s e l[2:0] b i ts i n t h e lcy c mo de r e g i s t er det e r m i n e w h ich v o l t a g e cha n ne ls a r e us e d fo r t h e zero-cr o ssin g det e c t io n. t h e s a m e sig n a l is a l s o us e d fo r lin e c y cle en erg y acc u m u l a t i o n m o de if ac t i v a t e d (s e e t h e l i n e c y cle a c c u m u la t i on m o de reg i st er (0x17) s e c t io n). overcurrent detection interrupt f i gur e 48 i l l u s t ra t e s t h e b e ha v i o r o f t h e o v er c u r r en t de t e c t ion. 04443-0-023 ipintlvl[7:0] read rstatus register pki interrupt flag (bit 15 of status register) pki reset low when rstatus register is read current peak waveform being monitored (selected by pkirqsel[2:0] in mmode register) f i gure 48. a d e 7 7 5 8 o v e r cu rrent d e te c t ion n o t e th a t th e c o n t e n t o f th e i p in t l v l [ 7 : 0 ] r e gi s t e r i s e q ui v a l e n t t o bi t 14 t o bi t 21 o f t h e c u r r en t wa vefo r m s a m p le . th er efo r e , s e tt i n g t h i s re g i s t e r to a 1 ( h e x ) re pre s e n t s put t i n g p e a k de te c t i o n at f u l l - s c a l e a n a l o g i n put . fi g u r e 4 8 s h ow s a c u r r e n t e x c e e d i n g a t h r e s h ol d . th e o v er c u r r en t e v e n t is r e co r d e d b y s e t t in g t h e p k i f l a g (b i t 15) in t h e in t e r r u p t s t a t us r e g i s t er . i f t h e p k i ena b le b i t is s e t t o l o g i c 1 in t h e in t e r r u p t mask r e g i st er , t h e ir q log i c o u t p u t g o es ac tiv e lo w (s ee t h e ad e7758 i n t e r r u p ts s e c t io n). s i mi la r t o p e a k le v e l det e c t io n, m u l t i p le p h as es ca n be ac t i v a t e d fo r p e a k dete c t i o n. i f an y o f t h e ac t i ve phas e p r o d u c es w a v e fo r m s a m p l e s a b o v e th e th r e s h o l d , th e p k i f l a g i n th e i n t e rru p t s t a t u s r e g i s t er is s e t. th e phas e o f w h i c h o v er c u r r en t i s m o ni t o r e d is s e t b y t h e pkirqs el[2:0] b i ts in t h e mm o d e r e g i s t er (s ee t a b l e 15). voltage c h annel adc f i gur e 49 sh o w s th e ad c and sig n al p r o c es sin g c h a i n fo r the i n put v a i n t h e volt age ch an n e l ( s ame for v b a n d v c ) .
ade7758 rev. a | page 23 of 68 04443-a - 024 adc to voltage rms calculation and waveform sampling to active and reactive energy caclulation vap + ? vn pga va gain[6:5] 1, 2, 4 lpf output word range 0xd869 0x0 0x2797 50hz lpf output word range 0xd8b8 0x0 0x2748 60hz 0xd7ae 0x0 0x2852 phase calibration phcal[6:0] analog input range va 0v 0.5v gain lpf1 f i g u re 49. a d c a n d sig n al proc es s i ng i n v o lt ag e ch ann e l f o r ac t i v e a nd r e ac t i v e e n erg y m e as ur e m en ts, t h e ou t p u t o f t h e a d c p a ss e s dire c t ly to t h e m u lt i p l i e r s and is not f i l t e r e d . t h is s o l u t i o n a v o i ds t h e m u ch la rg er m u l t ib i t m u l t i p lier a nd do es n o t a f fe c t t h e acc u r a c y o f t h e me asur em e n t. a hpf is n o t i m ple- m e n t e d o n t h e v o l t a g e cha n ne l t o r e m o v e t h e dc o f fs et b e c a us e t h e hp f o n t h e c u r r en t cha n ne l alo n e sh o u ld b e s u f f i cien t t o e l imina t e er r o r d u e t o ad c o f fs ets i n t h e p o w e r calc u l a t io n. h o w e v e r , ad c o f fs et in t h e v o l t a g e cha n ne ls p r o d uces l a rg e er r o rs in t h e v o l t a g e r m s calc u l a t io n an d a f fe c t s t h e acc u rac y o f t h e a p p a r e n t en erg y calc u l a t i o n. voltage channel s a mpling the w a v e fo r m s a m p les o n t h e vol t a g e cha n ne ls ca n als o b e route d to t h e w f or m re g i ste r . h o we ve r , b e f o re p a ss i n g to t h e wf or m re g i ste r , t h e a d c outp u t s p a ss t h rou g h a s i ng l e - p ol e , lo w-p a s s f i l t er ( l p f 1) wi th a c u t o f f f r eq uen c y a t 260 h z . f i gur e 50 sh o w s t h e ma g n i t ude a nd phas e r e s p on s e o f lp f1. this f i l t er a t t e n u a t es t h e sig n al s l ig h t l y . f o r exa m ple , if t h e l i n e f r e q u e n c y i s 6 0 h z , t h e s i g n a l at t h e o u tp ut of l p f 1 i s att e n u at e d b y 3.575%. th e wa v e f o r m s a m p les a r e 16-b i t, tw os co m p lem e n t da t a r a ng in g b e tw e e n 0x 27 48 (+ 10 ,0 56 d) and 0x d8 b8 ( ? 1 0 , 0 5 6 d ). the da t a a r e sig n ext e n d e d t o 2 4 b i t in t h e wf o r m r e g i s t er . () ? = = ? ? ? ? ? ? ? ? + = f h 0 ?20 ?40 ?60 ?80 0 ?10 ?20 ?30 ?40 10 100 1k 04443-0-005 frequency (hz) ph a se ( d egrees) gain ( d b) (60hz; ? 0.2db) (60hz; ?13 ) f i g u re 50. m a g n it u d e and p h as e r e s p ons e of lpf 1 n o t e t h a t l p f1 do es n o t a f fe c t t h e ac t i v e and r e ac t i v e e n erg y ca lc u l a t io n b e ca us e i t is us e d o n ly in t h e w a v e fo r m s a m p li n g s i g n a l p a t h . h o we ve r , w a ve for m s a m p l e s are u s e d for t h e v o l t a g e r m s c a lc u l a t ion an d t h e s u bs e q uen t a p p a r e n t e n erg y acc u m u la t i on. w a v s el[2:0] b i ts in t h e w a vm o d e r e gi s t er s h o u ld be set t o 001 (b ina r y) t o s t a r t v o l t a g e wa v e f o r m s a m p ling. p h s e l[1:0] b i ts co n t r o l t h e phas e f r o m w h ich t h e s a m p les a r e r o u t e d . w h e n in w a vefo r m s a m p l i ng mo de, one o f fo u r o u t p u t s a m p l e r a tes ca n b e ch o s e n b y cha n g i n g bi t 5 a nd bi t 6 o f t h e w a vmode r e g i s t er (s e e t a b l e 16). th e a v ai la b l e ou t p u t s a m p le ra t e s a r e 26.0 ks p s , 13 .5 ks ps , 6 . 5 ks ps , o r 3. 3 ks ps. b y s e t t in g t h e w s m p b i t i n t h e i n t e r r up t mask reg i st er t o l o g i c 1, t h e i n t e r r up t r e q u e s t output ir q g o es ac t i v e l o w w h en a s a m p le is a v a i l a bl e . f i gure 40 s h o w s t h e t i ming. th e 24 -b i t wa v e fo r m s a m p les a r e tra n sfer r e d f r o m th e ad e7 758 o n e b y t e (8 b i ts) a t a t i m e , wi th t h e m o s t sig n if ican t b y t e shif t e d o u t f i rst. the sig n o f t h e r e g i st er is ext e nde d in t h e u p p e r 8 b i ts. the t i min g is t h e s a m e as t h a t fo r t h e c u r r en t cha nne ls (s e e f i gur e 40).
ade7758 rev. a | page 24 of 68 zero-crossing detection the ad e7758 has zer o -cr o s s in g det e c t io n cir c u i ts f o r eac h o f t h e v o l t a g e channe ls (v an, vbn, o r v c n). f i g u r e 51 s h o w s how t h e z e ro - c ro ss s i g n a l i s ge n e r a te d f r om t h e output of t h e a d c of t h e volt age ch an n e l. 04443-0-031 reference adc zero- crossing detector pga van, vbn, vcn gain[6:5] 1, 2, 4 lpf1 f ? 3db = 260hz 24.8 @ 60hz analog voltage waveform (van, vbn, or vcn) lpf1 output read rstatus irq 1.0 0.908 f i g u re 51. zero - c r o s s i ng d e tec t i o n on v o lt ag e ch anne ls the z e r o -cr o ssin g in t e r r u p t is gen e ra t e d f r o m t h e o u t p ut o f lp f1. lp f1 has a sin g le p o le a t 260 h z (cl k in = 10 mh z). a s a r e su lt, t h ere is a phas e lag b e tw e e n t h e a n a l og in p u t sig n a l o f t h e v o l t a g e cha nne l and t h e o u t p ut o f lp f1. the phas e r e sp o n s e o f t h is f i l t er is sho w n i n t h e v o l t a g e c h a nnel sam p li ng s e c t io n. th e phas e l a g r e s p o n s e o f lp f1 r e s u l t s in a t i m e dela y o f a p p r o x ima t e l y 1.1 m s (@ 60 h z ) betw een t h e zer o -cr o s s in g sig n al o n t h e v o l t a g e in pu ts o f t h e zer o -cr o s s ing sig n al . n o t e t h a t t h e zer o -cros s in g sig n al is us e d fo r t h e li ne c y cle acc u m u la - t i on mo d e , z e ro - c ro ss i n g i n te r r upt , a n d l i ne p e r i o d / f re qu e n c y me a s u r e m e n t . w h en one phas e cr os s e s f r o m nega t i v e t o p o si t i v e , t h e co r r es p o n d in g f l a g in t h e i n t e r r u p t s t a t us r e g i ster (bi t 9 t o b i t 11) is s e t t o l o g i c 1. an ac tiv e lo w in t h e ir q output a l s o a p p e a r s if t h e c o r r esp o n d in g z x b i t i n t h e in te r r u p t mask r e g i s t er is s e t t o l o g i c 1. n o te tha t o n l y zer o cr os sin g f r o m n e ga ti v e t o posi ti v e w i ll g e n e ra t e a n in t e rr u p t . the f l a g in t h e i n t e r r u p t s t a t us reg i s t er is r e s e t to 0 w h e n t h e i n te r r upt s t atu s re g i ste r w i t h re s e t ( r st a t u s ) i s re a d . e a c h p h as e has i t s o w n in t e r r u p t f l a g a nd mask b i t in th e in t e r r u p t re g i ste r . zero-crossing timeo u t e a ch z e ro - c ro ss i n g d e te c t i o n h a s an a s s o c i a t e d i n te r n a l t i me out r e gis t e r (n o t a c ce s s i b le t o t h e us e r ). th i s un si g n ed , 16-b i t r e gis t er is decr eas e d b y 1 ev er y 384/ cl kin s e co n d s. th e r e g i st ers a r e r e s e t t o a co mmo n us er p r og ra mm e d v a l u e , i . e., t h e zer o - cr os sin g tim e o u t r e g i s t er (zxto u t[15:0], a d dr es s 0x1b), ev e r y ti m e a z e r o cr os s i n g i s d e t e ct ed o n i t s as so ci a t ed i n p u t . the def a u l t v a l u e o f zxto u t i s 0xffff . i f t h e in t e r n al r e g i s t er de cr em e n ts t o 0 b e fo r e a zer o cros sin g a t t h e cor r es p o n d in g in p u t is det e c t e d , i t in dic a t e s an a b s e n c e o f a zer o cr os sin g in t h e t i m e det e r m in e d b y t h e zx t o u t [15:0]. th e zxt o x det e c t io n b i t o f t h e co r r es p o ndi n g phas e i n t h e in t e r r u p t st a t us r e g i s t er is t h en swi t ch ed on (b i t 9 t o b i t 11). an ac ti ve lo w o n th e ir q o u t p u t als o a p p e a r s if t h e zxto x mask b i t fo r t h e c o rr e s po n d i n g phas e in t h e i n ter r u p t mas k r e g i st er is s e t t o l o g i c 1 . f i g u re 5 2 sh o w s t h e m e ch an i s m of t h e z e ro - c ro ss i n g t i m e o u t d e te c t i o n w h e n t h e li ne vol t a g e a st a y s a t a f i xe d dc lev e l f o r m o r e t h a n cl kin/38 4 zxt o ut[15:0] s e co n d s. 04443-0-032 zxtoa detection bit read rstatus voltage channel a zxtout[15:0] 16-bit internal register value f i gure 52. zero - c r o s s i ng t i me out d e te c t ion phase compensation w h en t h e hp f in t h e c u r r e n t cha nne l is dis a b l e d , t h e phas e er r o r b e tw e e n t h e c u r r en t cha n ne l (i a, ib , o r ic) a nd t h e co r r esp o n d in g v o l t a g e cha n ne l (v a, vb , o r v c ) is n e g l ig ib le . w h en t h e hp f is ena b le d, t h e c u r r en t cha n n e ls ha v e phas e r e s p o n s e (s e e f i gur e 53 a n d f i g u r e 54). f i gur e 55 is th e ma g n i - t u de r e sp o n s e of t h e f i l t er . th e phas e r e s p o n s e is alm o st 0 f r o m 45 h z t o 1 kh z. the f r eq uen c y ba nd is s u f f i cien t f o r th e r e q u ir emen t s o f typ i ca l e n erg y m e as ur e m en t a p plica t io n s . h o w e v e r , des p i t e b e in g i n ter n al l y phas e co m p e n s a t e d , t h e ad e7758 m u s t w o rk wi t h tra n s d ucers tha t ma y ha v e in h e r e n t phas e er r o rs. f o r exa m ple , a c u r r en t t r a n sfo r m e r (ct) w i t h a phas e er r o r o f 0.1 t o 0.3 is n o t un co mm on. th es e phas e er r o rs ca n va r y f r o m p a r t to p a r t , a n d t h e y m u st b e cor r e c te d i n o r der to p e r f or m a c c u r a te p o we r c a l c u l a t i o ns . t h e e r rors a s s o c i a t e d w i t h ph a s e m i s m a t c h are p a r t i c u l arly not i c e ab l e a t l o w p o we r fac t o r s. th e ade7758 p r o v ides a mea n s o f dig i t a l l y calib r a t in g t h ese smal l p h a s e err o r s . th e ad e7758 allo ws a small t i m e de la y o r tim e ad van c e t o be in tr o d uce d in t o t h e sig n a l p r o c es sin g cha i n in o r der to co m p en s a t e fo r t h e smal l phas e er r o rs.
ade7758 rev. a | page 25 of 68 the phas e cal i b r a t io n r e g i st ers (ap h c a l, bph c al, and cp h c al) a r e t w os co m p lem e n t , 7-b i t sig n e d r e g i s t ers t h a t can v a r y th e tim e ad v a n c e/ de la y in th e v o l t a g e c h a n n e l si gn al p a th f r o m C151.2 s t o +75.6 s (clkin = 10 m h z) . on e ls b is eq ui valen t t o 1.2 s o f time de l a y o r 2.4 s o f tim e ad van c e . w i t h a lin e f r e q uen c y o f 50 h z , t h is g i ves a p has e r e s o l u t i o n o f 0.02 6 a t th e f u n d a m en tal , i . e ., 36 0 1. 2 s 60 h z , in th e p o si ti v e dir e c t i o n a n d 0.052 in t h e n e ga t i ve dir e c t io n. thi s co r r esp o n d s to a t o tal co r r ec ti o n ra n g e o f ?2 .72 t o +1.3 6 a t 50 h z . f i gur e 56 i l l u s t ra t e s h o w t h e phas e co m p en s a t i o n is us e d t o r e m o v e a 0.1 phas e le ad i n i a o f t h e c u r r en t cha nne l f r o m t h e ext e r n al c u r r en t t r a n s d ucer . i n o r der t o ca n c e l t h e l e ad (0.1) i n t h e c u rr en t ch a n n e l o f ph ase a, a p h as e lead m u s t b e in tr o d uce d in t o t h e co r r es p o n d in g v o l t a g e cha nne l . th e r e s o l u t i o n o f t h e phas e ad j u st me n t a l lo ws t h e i n t r o d uc t i o n o f a phas e le a d o f 0.10 4. the phas e l e ad is achie v e d b y in tr o d uc ing a t i me ad van c e in t o v a . a tim e a d v a n c e o f ?4.8 s is m a de b y w r i t in g ?4 (0x3c) t o th e t i m e dela y b l o c k (ap h cal[7:0]), th us r e d u cing t h e a m o u n t o f tim e dela y b y 4.8 s o r eq ui valen t l y , 360 4.8 s 60 h z = 0.104 a t 60 h z . 04443-0-095 0 100 200 300 400 500 600 700 800 1k 900 90 0 10 20 30 40 50 60 70 80 frequency (hz) phase ( d egrees) f i g u re 53. phas e r e s p ons e of t h e hpf and p h as e co mpe n s a t i o n (10 h z to 1 k h z) 04443-0-096 40 70 65 60 55 50 45 0.20 0.15 0.10 0.05 0 ?0.05 ?0.10 frequency (hz) ph a se ( d egrees) f i g u re 54. phas e r e s p ons e of t h e hpf and p h as e co mpe n s a t i o n (40 h z to 7 0 h z ) 04443-0-097 44 56 54 52 50 48 46 0.10 0.08 0.06 0.04 0.02 0 ?0.02 frequency (hz) ph a se ( d egrees) f i g u re 55. g a in r e s p ons e of h p f and phas e co mpens a t i o n (44 h z to 5 6 h z ) 04443-a - 029 pga1 iap ian ia adc hpf pga2 vap vn va adc 60hz 0.1 v2 v1 range of phase calibration 111 11 00 60 aphcal[6:0] ?151.2 s to +75.6 s va va delayed by 4.8 s ( ? 0.104 @ 60hz) 0x7c ia 60hz digital integrator active and reactive energy calculation +1.36, ? 2.72 @ 50hz; 0.022, 0.043 +1.63, ? 3.28 @ 60hz; 0.026, 0.052 f i g u re 56. phas e cal i br at io n on v o lt a g e cha nne ls
ade7758 rev. a | page 26 of 68 period measurement the ad e7758 p r o v ides t h e p e r i o d o r f r eq uen c y m e as ur emen t o f th e l i ne v o l t ag e . th e p e r i o d is m e as ur ed o n t h e p h as e s p e c if ie d b y bi t 0 t o bi t 1 o f t h e mmo d e r e g i s t er . the p e r i o d r e g i s t er is a n unsig n e d 12-b i t f r eq r e g i s t er and is u p da t e d ev e r y 4 pe ri od s o f th e s e l e ct ed ph a s e . bi t 7 o f t h e l c y c mo d e s e le c t s w h et h e r t h e p e r i o d r e g i s t er d i s p la ys t h e f r eq uen c y o r th e p e r i o d . s e t t i n g t h i s b i t t o logi c hig h ca us es t h e r e g i s t er t o dis p l a y t h e p e r i o d . th e defa u l t s e t t in g is log i c l o w , w h ich c a us e s t h e reg i st er t o displ a y t h e fr e q u e n c y . w h en s e t t o me as ur e t h e p e r i o d , t h e r e s o l u t i on o f t h is r e g i s t e r is 96/clki n p e r ls b (9.6 s/ls b when clki n is 10 mh z), which r e p r es en ts 0.06% w h en t h e l i n e f r eq uen c y is 60 h z . a t 6 0 h z , t h e val u e o f th e p e r i o d r e g i s t er is 1737d . a t 50 h z , t h e val u e o f th e p e r i o d r e g i s t er is 2084d . w h en s e t t o me as ur e f r eq uen c y , th e val u e o f t h e p e r i o d r e g i st er is a p p r o x ima t e l y 960d a t 60 h z a nd 800d a t 50 h z . this is eq u i valen t t o 0.0625 h z /ls b . line vol t a g e sag det e ctio n the ad e7758 c a n b e p r og ra mm e d t o det e c t w h en t h e a b s o l u te val u e o f t h e li ne v o l t a g e o f a n y phas e dr o p s b e lo w a cer t a i n p e a k val u e , fo r a n u m b er o f half c y cles. e a ch phas e o f t h e v o l t a g e cha nnel is con t r o l l e d sim u l t an e o usly . this condi t i on is il l u s t ra t e d in f i gur e 57. 04443-a - 033 saglvl[7:0] full-scale read rstatus register s a g c y c [ 7 : 0 ] = 0x06 6h a l f c y c l e s s ag interrupt flag (bit 3 to bit 5 of status register) vap, vbp, or vcp sag event reset low when voltage channel exceeds saglvl[7:0] f i g u re 57. a d e 7 7 5 8 sa g d e tec t i o n fi g u r e 5 7 s h ow s a l i n e v o lt a g e f a l l b e l o w a t h r e s h o l d w h i c h i s s e t in t h e sa g le ve l r e g i s t er (sa g l v l[7:0]) f o r nine half c y c l es. since t h e sa g c y cle r e g i s t er indica t e s a six half - c ycle t h r e s h old (sa g cy c[7:0] = 0x06), th e sa g ev en t is r e co r d ed a t t h e end of t h e s i xt h half c y cle b y s e t t in g t h e sa g f l a g o f t h e co r r es p o nding phas e i n t h e i n ter r u p t s t a t us r e g i s t er (bi t 1 t o bi t 3 i n t h e in t e r r u p t st a t us r e g i st er). i f t h e sa g ena b le b i t i s s e t t o l o g i c 1 fo r t h is phas e (bi t 1 t o bi t 3 in t h e in t e r r u p t m a sk r e g i st er), t h e ir q log i c o u t p u t g o es ac ti v e lo w (s e e the ad e7758 i n ter r u p ts s e c t io n). th e phas es a r e co m p a r e d t o t h e s a me p a ra m e t e rs def i n e d i n t h e s a gl vl a nd sa gcy c r e g i sters. sag level set the c o n t e n t s o f t h e s i ng l e - b yte s a g l e ve l reg i st er , sa gl vl[0 :7], a r e co m p a r e d to t h e abs o l u te v a l u e o f bi t 6 t o bi t 13 f r o m t h e vol t age w a ve for m s a m p l e s . f o r e x am pl e, t h e nomi na l m a x i m u m co de o f t h e v o l t a g e cha n ne l w a v e fo r m s a m p les wi t h a f u l l -s c a l e sig n al in p u t a t 6 0 h z is 0x249c (s ee t h e v o l t a g e cha nne l sa m p lin g s e c t io n). b i t 13 t o b i t 6 a r e 0x92. th eref o r e , wr i t ing 0x92 t o t h e sa g le v e l r e g i s t er p u ts t h e sa g de t e c t io n l e v e l a t full sc al e a n d set s th e s a g de t e cti o n t o i t s m o s t se n s i t i v e v a l u e . the de te c t ion is made w h en t h e co n t e n t o f t h e s a gl vl[ 7 :0] r e g i s t er is g r ea ter tha n t h e in co min g s a m p le . w r i t in g 0x00 p u ts t h e sa g de te c t i o n le vel a t 0. t h e dete c t io n o f a de cr e a s e o f a n in p u t v o l t a g e is in t h is cas e dis a b l e d . peak voltage detec t ion the ad e7758 c a n r e co r d t h e p e ak o f t h e v o l t ag e wa v e f o r m and p r o d uce an i n t e r r u p t if t h e c u r r en t exce e d s a p r es et li mi t. peak volt age det e ction usi n g the vpeak register the p e ak abs o l u t e val u e o f t h e v o l t a g e w a v e fo r m wi t h i n a f i xe d n u m b er o f half- l ine c y cles is s t o r e d in t h e vp e a k r e g i st er . f i g u r e 5 8 i l l u s t r a t e s th e ti m i n g be h a v i o r o f th e pe a k v o l t a g e dete c t io n. 04443-0-034 l2 l1 content of vpeak[7:0] 00 l1 l2 l1 no. of half line cycles specified by linecyc[15:0] register voltage waveform (phase selected by peaksel[2:4] in mmode register) f i gur e 5 8 . p e a k v o lta g e de te ctio n using the vp eak re gi s t e r n o te t h a t t h e con t e n t o f t h e v p ea k reg i st er is e q u i va le n t t o bi t 6 t o bi t 1 3 o f t h e 1 6 -b i t v o l t a g e wa v e f o r m s a m p l e . a t f u l l - s c al e a n al og in p u t , th e v o l t a g e wa v e f o rm sa m p le a t 60 h z is 0x2 4 9c. the vpea k a t f u l l - s c a le i n p u t is , t h er efo r e , ex p e c t e d t o b e 0x 92. i n ad di ti o n , m u l t i p le p h a s e s ca n b e a c ti v a t e d f o r th e p e ak de te c t i o n s i m u lt ane o u sly b y s e tt i n g m u lt i p l e b i t s to l o g i c h i g h a m o n g t h e p e a k s e l[2:4] b i t s i n t h e mmo d e r e g i s t er . th es e b i ts s e le c t t h e phas e fo r b o t h v o l t a g e and c u r r en t p e ak m e as ure- m e n t s. n o t e tha t if m o r e t h a n on e b i t is s e t, t h e vp eak an d ip eak r e g i st ers ca n h o ld v a l u es f r o m tw o dif f er en t phas es, i . e . , t h e v o l t a g e and c u r r en t p e a k a r e i n de p e n d e n t l y p r o c es s e d (s e e t h e p e a k c u r r en t d e t e c t ion s e c t io n).
ade7758 rev. a | page 27 of 68 n o t e t h a t t h e n u m b er o f half-l i n e c y cles is b a s e d o n co u n t i n g t h e zer o cr os sing o f t h e v o l t a g e cha nne l . th e z x s e l[2:0] b i ts i n t h e lcy c mo de r e g i s t er det e r m i n e w h ich v o l t a g e cha n ne ls a r e us e d fo r t h e zero-cr o ssin g det e c t io n. t h e s a m e sig n a l is a l s o us e d fo r lin e c y cle en erg y acc u m u l a t i o n m o de if ac t i v a t e d (s e e t h e l i n e c y cle a c c u m u la t i on m o de reg i st er (0x17) s e c t io n). over voltag e det e ction inte rru pt f i gur e 59 i l l u s t ra t e s t h e b e ha v i o r o f t h e o v er v o l t a g e de t e c t ion. 04443-0-035 vpintlvl[7:0] read rstatus register pkv interrupt flag (bit 14 of status register) pkv reset low when rstatus register is read voltage peak waveform being monitored (selected by pkirqsel[5:7] in mmode register) f i gure 59. a d e 7 7 5 8 o v er v o ltag e d e te c t ion n o t e t h a t t h e con t e n t o f t h e v p i n tl vl[7:0] r e g i s t er is eq ui valen t t o b i t 6 t o b i t 13 o f t h e 16-b i t v o l t a g e wa vef o r m s a m p les; t h er efo r e , s e t t in g t h is r e g i s t er t o 0x92 r e p r es en ts p u t t in g t h e p e a k de t e c t io n a t f u l l -s ca le ana l og in p u t. f i gur e 59 sho w s a vol t a g e exce e d in g a t h resh ol d . by s e t t i n g t h e pkv f l a g (bi t 14) in t h e i n t e r r u p t s t a t us reg i s t er , t h e o v er v o l t a g e e v en t is r e co r d e d . i f t h e pkv en a b le b i t is s e t t o l o g i c 1 in t h e in t e r r u p t mas k r e g i st er , t h e ir q log i c o u t p u t g o es ac ti v e lo w (s e e t h e ad e7758 i n t e r r u p ts s e c t io n). m u l t i p le phas es ca n b e ac t i v a te d fo r p e a k d e te c t io n. i f an y o f t h e ac t i v e phas e p r o d uces wa v e fo r m s a m p les a b o v e t h e t h re shol d, t h e p k v f l ag in t h e i n te r r u p t st a t u s re g i ste r is s e t. the phas e in w h ich o v er v o l t a g e is m o ni t o r e d i s s e t b y t h e p k ir qs el[5:7] b i ts in t h e mmo d e r e g i s t er (s e e t a b l e 15). phase sequence dete ction the ad e7758 has o n -c hi p p h as e s e q u en ce er r o r det e c t ion in t e r r u p t. i f t h e zer o cr os sin g o f p h as e a is n o t f o l l o w ed b y p h as e c b u t b y p h as e b , t h e s e qerr b i t (bi t 1 9 ) in t h e st a t us r e g i s t er is s e t. i f s e qerr , bi t 1 9 , is s e t i n t h e mas k r e g i st er , t h e ir q log i c o u t p u t g o es ac ti v e lo w (s e e the ad e7758 i n ter r u p ts s e c t io n). t h e fol l o w in g f i gur e dep i c t s ho w t h e in t e r r u p t is issue d in tw o d i f f er en t co nf igura t io n s . n o t e t h a t if i t is desir e d t o ha v e t h e in t e r r u p t o c c u r w h en p h as e a is fol l o w e d b y p h as e b and n o t p h as e c, t h en t h e a n alog in pu t s fo r p h as e b a nd phas e c sho u ld b e s w a p p e d . i n t h is cas e , t h e phas e b v o l t a g e i n p u t sho u ld b e w i r e d to t h e v c p p i n and t h e phas e c v o l t a g e i n p u t sho u ld b e w i r e d to t h e v b p p i n. 04443-a-051 voltage w aveform s zero crossings ab c a b c ab c ab ca b ca b c voltage waveforms zero crossings seqerr bit of status register is set seqerr bit of status register is not set a = 0 c b = ? 120 c c = 120 c a = 0 c c = ? 120 c b = 120 c f i g u re 60. phas e s e quenc e d e tec t io n power-supply monitor the ad e7758 a l s o co n t a i n s an o n -c hi p p o w e r - s u p p l y m o ni t o r . the ana l o g su pply ( a v d d ) is mon i tore d c o n t in u o u sly b y t h e ad e7758. i f t h e s u p p l y is les s t h a n 4 v 5%, t h e ad e7758 g o es in t o an inac ti v e s t a t e, tha t is, n o en erg y is acc u m u l a t e d w h e n t h e su p p ly v o lt a g e is b e l o w 4 v . t h is is us ef u l t o e n sur e c o rr ect d e vi ce op er a t ion a t p o wer - u p an d d u r i ng p o w e r - do wn . the p o wer - supply moni tor has b u i l t - i n h y ste r e s is and f i lte r ing . this g i ves a hi g h de gr ee o f i m m u ni t y t o f a ls e tr igg e r i n g d u e t o n o i s y s u p p l i e s . f i gur e 61 sh o w s t h e b e ha vio r o f t h e ad e7758 w h en t h e v o l t a g e o f a v d d fal l s b e l o w t h e p o w e r - s u p p l y m o ni t o r thr e sho l d . th e p o w e r s u p p l y a n d d e co u p lin g f o r th e p a r t shou l d b e de s i g n e d su c h t h a t t h e r i p p l e a t a v dd do e s not exce e d 5 v 5% as sp e c if ie d fo r n o r m a l o p er a t io n. 04443-0-036 av dd 5v 4v 0v ade7758 internal c alculation s active inactive inactive time f i gure 61. o n - c hip p o w e r - sup p l y mon i to ring
ade7758 rev. a | page 28 of 68 reference circuit the n o minal r e fer e n c e v o l t a g e a t t h e ref in/ou t p i n is 2.42 v . this is t h e refer e nce v o l t a g e u s e d fo r t h e a d c s i n t h e ad e 775 8. h o w e v e r , t h e c u r r en t cha n n e ls ha v e t h r e e in p u t ra n g e s e le c t ion s (f u l l s c ale is s e le c t a b le am o n g 0. 5 v , 0.25 v , and 0.125 v). this is a c hiev ed b y di vidi n g th e r e f e r e n c e in t e r n al l y b y 1 , ? , a n d ? . th e r e fer e nc e v a l u e i s us e d fo r t h e a d c i n t h e c u r r e n t channe ls . n o te t h a t t h e f u l l - s c al e s e le c t ion i s only a v ai lab l e fo r t h e c u r r e n t i n pu t s . the ref in/ou t p i n can b e o v erdr i v en b y a n ext e r n al s o ur ce , fo r e x am pl e, an e x t e r n a l 2 . 5 v re fe re nc e. n o t e t h a t t h e nom i n a l r e f e r e n c e val u e s u p p l i e d t o t h e ad cs is n o w 2. 5 v a n d n o t 2. 42 v . this has t h e ef fe c t o f in cr e a s i ng t h e n o minal analog in p u t sig n al ra n g e b y 2.5/2.4 2 100% = 3% o r f r o m 0.5 v t o 0.5165 v . the v o l t a g e o f th e ad e7758 r e f e r e n c e dr if ts s l ig h t l y wi t h t e m p era t ur es e e t h e s p e c if i c a t io n s s e c t ion fo r t h e t e m p era t ur e co ef f i cien t s p e c i f ica t io n ( i n p p m/ c ). th e v a l u e o f t h e t e m p era - t u r e dr if t va r i es f r o m p a r t t o p a r t . b e c a us e t h e refer e n c e is us e d f o r a l l a d c s , an y x % d r i f t i n t h e re f e re nc e re su lt s i n a 2 x % de v i a t io n o f t h e m e ter acc u r a c y . the r e fer e n c e dr if t r e su l t i n g f r o m t e m p era t u r e cha n g e s is us ual l y v e r y smal l a nd typ i cal l y m u ch s m a l l e r t h an t h e d r i f t of ot he r c o m p o n e n t s on a me t e r . a l t e r n at i v e l y , t h e m e t e r c a n b e c a l i b r at e d a t mu l t i p l e t e m p era t ur es. temperature measurement the ad e7758 a l s o in c l u d es a n o n -c hi p t e m p er a t ur e s e n s o r . a t e m p era t ur e m e as ur em e n t is made e v er y 4/clkin s e con d s. the o u t p u t f r o m t h e t e m p era t ur e s e n s in g c i r c ui t is co nn e c t e d t o a n ad c fo r dig i t i zi n g . t h e r e su lt a n t co de is p r o c ess e d and place d in t h e t e m p era t ur e r e g i st er (temp[7:0]). this r e g i s t er ca n b e r e a d b y t h e us er and has a n ad dr ess o f 0x 11 (s e e t h e ad e7758 s e r i a l i n t e r f ace s e c t ion). th e con t en ts o f th e tem p era - tu re re g i ste r are s i g n e d ( t wo s c o m p l e me n t ) w i t h a re s o lut i on of 3c/ls b . th e o f fs et o f this r e g i st er ma y va r y f r o m p a r t t o p a r t sig n if ican t l y . t o cal i b r a t e t h is r e g i s t er , t h e n o mi nal val u e sh o u ld be m e as ur ed , a n d t h e eq ua t i o n s h o u ld b e ad j u s t ed a c co r d i n gl y . f o r exa m ple , if t h e t e m p era t ur e r e g i s t er p r o d uc es a co de o f 0x0 0 w h en t h e am b i e n t t e m p er a t ur e i s a p p r o x ima t e l y 70c, t h e v a l u e o f t h e r e g i st er is t e m p er a t u r e re g i s t er = te m p e r a t u r e (c) ? 70 d e p e nding o n t h e n o m i na l v a l u e o f t h e r e g i ster , s o m e f i ni te t e m p era t ur e ma y ca us e t h e r e g i st er t o r o l l o v er . this sh o u ld b e co m p ens a t e d i n t h e mc u . the ad e7758 tem p er a t ur e r e g i s t er va r i es wi th p o w e r s u p p l y . i t is r e co mm e nde d t o us e t h e tem p er a t ur e r e g i s t er o n l y in ap p l i c at i o n s w i t h a f i x e d , s t a b l e p o w e r s u p p l y . t y p i c a l e r r o r wit h re s p e c t to p o we r su p p ly v a r i a t ion is s h ow i n t a bl e 5 . table 5. tem p e r ature register error with power supply variation 4.5 v 4.75 v 5 v 5.25 v 5.5 v register value 219 216 214 211 208 % error 2.34 0.93 0 ? 1.40 ? 2.80 root mean square measurement r o ot me an s q u a re ( r ms ) i s a f u n d a me n t a l m e a s u r e m e n t of t h e ma g n i t u d e o f an ac sig n a l . i t s d e f i ni t i on can b e b o t h p r ac t i c a l a nd ma t h ema t i c al . d e f i n e d p r ac t i cal l y , t h e r m s val u e as sig n e d t o a n ac sig n al is th e amo u n t o f dc r e q u ir ed t o p r o d uce a n e q u i v a l e nt a m o u nt o f p o w e r i n t h e l o a d . m a t h e m at i c a l l y t h e r m s val u e o f a c o n t in uo us sig n a l f ( t ) is def i n e d as dt t f t frms 0 t 2 1 ( 1 ) f o r t i m e s a m p lin g sig n als, r m s calc u l a t io n in v o l v es s q ua r i n g t h e sig n al, t a k i n g t h e a v era g e , an d ob t a i n ing t h e s q u a r e r o o t . @ n 1 n 2 n f n frms 1 ( 2 ) the m e t h o d us ed t o calc u l a t e t h e r m s val u e in th e ad e7758 is t o lo w-p a s s f i l t er th e s q ua r e o f t h e in p u t sig n al ( l p f 3) a nd tak e t h e s q u a re ro ot of t h e re su lt ( s e e f i g u re 6 2 ) . wi t h i ( t ) = t) sin( 2 z u u irms th en i 2 ( t ) = irms 2 ? irms 2 cos t) ( z the r m s c a lc u l a t ion is si m u lt ane o usly p r o c e s s e d o n t h e s i x a n a l o g in p u t cha n ne ls. e a ch r e s u l t is a v a i la b l e i n s e p a ra t e r e g i s t ers. w h ile t h e ad e 7758 m e as ur es n o n s in us o i dal s i g n als, i t sh o u ld b e n o t e d t h a t t h e v o l t a g e r m s me as ur emen t, and t h er efo r e t h e a p p a r e n t en erg y , a r e ba nd-l i mi ted t o 160 h z . th e c u r r en t r m s, as w e l l as t h e ac t i v e p o wer , ha v e a b a n d wi d t h o f 14 khz. cu rrent rms ca lcu l a t ion f i g u r e 62 s h o w s th e d e ta il o f th e s i gn al p r oce s s i n g c h a i n f o r th e r m s c a lc u l a t i o n o n on e o f t h e phas e s o f t h e c u r r e n t channe l. the c u r r en t cha n ne l r m s val u e is p r o c es s e d f r o m t h e s a m p les us e d in t h e c u r r e n t cha nne l w a v e fo r m s a m p l i n g m o de . the c u r r en t r m s val u es a r e st o r e d in un sig n e d 24-b i t r e g i s t e r s (airms, b i rms, and ci rms). one ls b o f t h e c u r r en t r m s r e g i s t er is
ade7758 rev. a | page 29 of 68 e q ui vale n t t o o n e ls b o f t h e c u r r en t w a v e fo r m s a m p le . the u p da te ra te o f t h e c u r r en t r m s m e as ur e m en t is clki n/12. 04443-a - 016 sgn 2 25 2 24 2 23 2 17 2 16 2 15 current signal from hpf or integrator (if enabled) 0x1d3781 0x00 + + 0x2851ec 0x0 0xd7ae14 x 2 lpf3 airms[24:0] airmsos[11:0] f i gure 62. c u r r ent rms signal proc ess i ng w i t h t h e sp e c if ie d f u l l -s c a le a n a l og in p u t sig n a l o f 0.5 v , t h e ad c p r o d u c es a n o u t p u t co de t h a t is a p p r o x ima t e l y 2 ,6 42 ,412 d (s e e t h e c u r r en t c h a n n e l ad c secti o n ) . th e e q u i v a l e n t rm s val u es o f a f u l l -s cale sin u s o idal s i g n al a t 60 h z is 1,914,753 (0x1d3781). the acc u rac y o f t h e c u r r e n t r m s is typ i cal l y 0.2 % er r o r f r o m th e f u l l -s c a le in p u t do wn t o 1/500 o f th e f u l l -s cale in p u t. a d di ti o n all y , thi s m e as ur em e n t h a s a ba n d w i d t h o f 14 k h z . cu rrent rms offset co mpensa tion the ad e7758 in co r p o r a t es a c u r r en t r m s o f fs et co m p en s a t i o n f o r eac h p h as e (airmsos, b i rmsos, an d ci rmsos). th es e a r e 12-b i t sig n e d r e g i s t ers t h a t ca n b e us e d t o r e m o ve o f fs ets in t h e c u r r en t r m s calc u l a t io n s . a n o f fs et ma y exis t in t h e r m s calc u l a t io n d u e t o in p u t n o is es t h a t a r e i n teg ra t e d i n t h e dc co m p on en t o f i 2 (t). the o f fs et c a lib r a t ion al lo w s t h e co n t e n ts of t h e i r ms r e g i s ters t o b e main t a in e d a t 0 w h e n n o c u r r en t is b e i n g co n s u m e d . o n e ls b o f t h e c u r r en t r m s o f fs et r e g i s t er is eq ui valen t t o 16,384 (decimal) o f th e s q ua r e o f th e c u r r en t r m s r e g i s t er . a s s u mi n g t h a t t h e max i m u m va l u e f r o m t h e c u r r en t r m s calc u l a t ion is 1,868,467d wi th f u l l -s c a le ac in p u ts, one ls b o f t h e c u r r en t r m s o f fs et r e p r es en ts 0.94 % o f t h e m e as ur e m en t er r o r a t ?60 db do wn o f f u l l s c a l e . f o r deta ils o n ho w t o cal i b r a t e t h e c u r r en t r m s m e as u r em e n t, s e e t h e c a l i b r a t io n secti o n . irmsos irms irms 0 + = 384 , 16 2 w h er e irms 0 is t h e r m s m e as urem e n t w i t h o u t o f fs et co r r e c t i o n . voltage channel rms c a lculation f i g u r e 63 s h o w s th e d e ta ils o f th e s i gn al pa t h f o r th e rm s calc u l a t io n on phas e a o f t h e v o l t a g e chann e l. th e v o l t a g e cha nne l r m s value is p r o c es s e d f r o m t h e w a v e fo r m s a m p les a f t e r t h e l o w-p a s s f i l t er lp f1. th e o u t p ut o f t h e v o l t a g e cha n ne l ad c can be s c a l ed b y 50 % b y c h a n g i n g vrm s gain[11:0] r e g i s t ers t o p e r f o r m a n o v eral l r m s v o l t a g e cal i b r a t io n. th e vrmsgai n r e g i s t ers s c ale t h e r m s calc u l a t io ns as w e l l as t h e ap p a r e nt e n e r g y c a l c u l at i o n , s i n c e ap p a r e n t p o w e r i s t h e p r o d uc t o f t h e vol t a g e an d c u r r en t r m s v a l u es. th e v o l t a g e r m s val u es a r e s t o r e d i n un sig n e d 2 4 -b i t r e g i s t ers ( a vrms, b v r m s, a nd cvrms). the 256 ls bs o f th e v o l t a g e r m s r e g i s t er is a ppro x i m a t ely e q u i v a l e n t to one l s b of a volt ag e w a v e for m s a m p le . the u p da t e ra t e o f t h e v o l t a g e r m s m e as ur em e n t is clki n /12. w i t h t h e sp e c if ie d f u l l -s c a le ac a n a l og in p u t sig n a l o f 0.5 v , t h e lp f1 p r o d uces a n o u t p u t co de tha t is a p p r o x ima t e l y 63% o f i t s f u l l -s cale val u e , i . e ., 9,372 d , a t 60 h z (s e e t h e v o l t a g e cha n nel ad c s e c t io n). the e q uivale n t r m s val u e o f a f u l l -s cale ac sig n al is a p p r o x ima t e l y 1,639,101 (0x1902b d) in t h e vrms r e g i s t er . the acc u rac y o f t h e vrms m e as ur em e n t is typ i cal l y 0.5% er r o r f r o m t h e f u l l -s c a le in p u t do wn t o 1/20 o f t h e f u l l -s cal e i n p u t. a d di tio n al l y , this m e as ur em en t has a ban d wid t h o f 160 h z . van avrmsgain[11:0] 0x249c lpf output word range 0x0 60hz 0xdb64 0x25a2 lpf output word range 0x0 50hz 0xda5e lpf1 voltage signal ? v(t) 0.5 gain 04443-a-030 0x193504 50hz 0x0 0x1902bd 60hz 0x0 x 2 avrms[23:0] lpf3 sgn 2 16 2 15 2 14 2 8 2 7 2 6 vrmsos[11:0] + + f i g u re 63. v o lt ag e r m s sig n a l proc es s i ng voltage rms offset co mpe n sation the ad e7758 in co r p o r a t es a vol t a g e r m s o f fs et co m p en s a t i o n f o r eac h p h as e (a vrmsos, b v rmsos, an d cvrmsos). th e s e a r e 12- b i t sig n e d r e g i s t ers t h a t can b e us e d t o r e mo v e o f fs ets in t h e v o l t a g e r m s calc u l a t io n s . a n o f fs et ma y exis t i n t h e r m s calc u l a t i on d u e t o i n p u t n o i s es a nd o f fs ets i n t h e i n p u t s a m p les. i t sh o u ld b e n o t e d t h a t t h e o f fs et c a l i b r a t io n do es n o t al lo w t h e con t e n ts o f t h e v r m s r e g i s t ers t o b e ma in t a i n e d a t 0 w h en n o v o l t a g e is a p plie d . thi s is ca us e d b y no is e in t h e v o l t a g e r m s c a lc u l a t ion, w h ich l i mi ts t h e us a b le ra n g e b e tw e e n full sc al e a nd 1/50t h o f f u l l s c ale . o n e lsb o f t h e v o l t a g e r m s o f fs et is e q ui vale n t t o 64 ls bs o f t h e v o l t a g e r m s r e g i st er . a s sumi n g t h a t t h e maxim u m v a l u e f r o m t h e v o lt a g e r m s calc u l a t io n is 1, 639,101d wi t h f u l l -s cale ac in p u ts, t h en 1 ls b o f t h e v o l t a g e r m s o f fs et r e p r es en ts 0.042 % o f t h e m e as ur e m en t er r o r a t 1/10 o f f u l l s c ale . 64 + = vrmsos vrms vrms 0 w h er e vrm s 0 is t h e r m s me as urem e n t w i t h o u t t h e o f fs et co rr ecti o n .
ade7758 rev. a | page 30 of 68 voltage rms gain a d just the ad c ga in i n e a ch phas e o f t h e v o l t a g e channe l can b e ad j u s t e d fo r t h e r m s calc u l a t ion b y usin g t h e v o lt a g e r m s ga i n r e g i s t ers (a vr msgain, b v r m sgain, and cvrmsg ain). the ga i n o f t h e v o l t a g e w a v e fo r m s b e fo r e lp f1 is ad j u s t e d b y wr i t in g tw os com p le m e n t , 12- b i t w o r d s t o t h e vol t a g e r m s ga i n r e g i s t ers. th e e x p r es sio n b e lo w s h o w s h o w t h e ga in ad j u s t m e n t is r e la t e d t o t h e co n t e n ts o f t h e v o l t a g e ga i n r e g i s t er . ? ? ? ? ? ? + = 12 2 vrmsgain gain without values rms nominal register vrms of content 1 f o r exa m ple , w h e n 0x7ff is wr i t t e n t o t h e v o l t a g e ga i n r e g i s t er , t h e ad c o u t p ut is s c ale d u p b y 50%. 0x7ff = 2047d , 2047/2 12 = 0.5 s i mi la rl y , 0x800 = C2047d (sig ned tw os co m p lem e n t ) an d the ad c o u t p u t is s c a l e d b y C50 % . active power calculation e l ec tr ical p o wer is def i n e d as t h e ra t e o f en er g y f l o w f r o m s o ur ce t o lo ad . i t is g i v e n b y t h e p r o d uc t o f t h e vol t a g e an d c u r r en t w a v e fo r m s. th e r e s u l t i n g wa v e fo r m is cal l e d t h e in s t an tan e o u s p o w e r sig n al an d i t is eq ual t o t h e ra t e o f en er g y f l o w a t e v er y ins t a n t o f t i m e . th e uni t o f p o w e r is t h e wa t t o r jo ule s / s ec. eq ua ti o n 5 gi v e s a n exp r e s s i o n f o r th e i n s t a n t a n e o u s p o w e r sig n al in a n ac sys t e m . () ( t vrms t v = sin 2 ) (3) () ( ) t irms 2 t i = sin (4) w h er e vrm s = r m s v o l t a g e , ir ms = r m s c u r r en t. ( ) ( ) ( ) t i t v t p = t) (2 vrms irms C vrms ms r i (t) p = cos (5) the a v er a g e p o w e r o v er a n i n t e g r al n u m b er o f line c y cles (n) is g i v e n b y t h e ex p r es sio n in e q u a t i o n 6. () irms vrms dt t p nt 1 p nt 0 = = (6) w h er e t is t h e l i n e c y cle p e r i o d . p i s r e f e rr ed t o a s th e a c ti v e o r r e al po w e r . n o t e th a t t h e a c ti v e p o w e r is e q ual to t h e dc co m p on e n t o f t h e i n s t an t a n e o u s p o wer sig n al p ( t ) i n eq ua ti o n 5, tha t i s , vrm s irms . this is t h e r e la t i o n shi p us e d t o calc u l a t e t h e ac ti v e p o w e r in t h e ad e7758 fo r e a ch phas e. the inst an t a n e ous p o w e r sig n a l p ( t ) is g e n e ra t e d b y m u l t i p lyi n g t h e c u r r en t an d v o l t a g e sig n als i n e a ch phas e . the dc com p onen t o f t h e i n s t an t a n e o u s p o w e r sig n al i n e a ch phas e (a, b , and c) is t h en ext r ac t e d b y lp f2 (t h e lo w-p a s s f i l t er) t o ob t a i n t h e a v er a g e ac t i v e p o w e r i n fo r m a t io n on e a ch p h as e . f i gur e 6 4 s h o w s this p r o c es s. th e ac ti v e p o w e r o f eac h phas e acc u m u l a t e s in t h e co r r es p o ndi n g 16-b i t wa t t - h o u r r e g i s t er (a w a t t hr , b w a t thr , o r cw a t thr). th e in p u t t o e a ch ac t i ve e n er g y r e g i ster ca n b e chan ge d d e p e nding o n t h e a c cum u la ti o n m o d e s e t t i n g (s ee t a b l e 17). 04443-a - 037 instantaneous power signal p(t) = vrms irms ? vrms irms cos(2 t) a c t i v e re al p o w e r s i g n a l = v rms i rms 0x19999a vrms irms 0xccccd 0x00000 current i(t) = 2 irms sin( t) voltage v(t) = 2 vrms sin( t) f i gure 64. ac tive p o w e r cal c ul ati o n b e ca us e lp f2 do es n o t ha v e an ide a l b r i ck wal l f r e q uen c y re sp ons e ( f i g u r e 6 5 ) , t h e a c t i ve p o we r s i g n a l h a s s o m e r i ppl e d u e t o t h e in st an t a n e o u s p o wer sig n al . this r i p p l e is sin u s o idal a n d h a s a f r eq ue n c y eq ual t o tw i c e t h e lin e f r eq ue n c y . b e ca us e t h e r i p p le is si n u s o ida l in na t u r e , i t is r e m o v e d w h en t h e ac t i ve po w e r s i gn al i s in t e gra t e d o v e r t i m e t o calcu l a t e th e en e r g y . 04443-0-038 0 ?4 ?8 ?12 db ?16 ?20 ?24 13 1 0 8 frequency (hz) 30 100 f i gure 65. f r equen c y r e sponse of the lpf used to f i l t er ins t ant a ne ous p o wer in ea ch p h as e
ade7758 rev. a | page 31 of 68 active power gain cali brati o n sign of acti v e power cal c ul ation n o t e t h a t t h e a v era g e ac t i ve p o w e r r e s u l t f r o m t h e lp f o u t p u t in each p h as e can b e s c aled b y 50% b y wr i t in g t o th e p h as e s wa t t gain reg i st e r (a w g , b w g , o r c w g). th e wa t t gain reg i st e r s are t w o s c o m p l e me n t , s i g n e d re g i ste r s an d h a ve a re s o lut i on of 0.024%/ls b . the f o l l o w in g eq u a tio n des c r i bes ma t h ema t ic al l y t h e f u n c t i o n o f t h e wa t t gain r e g i s t ers. n o t e t h a t th e a v e r a g e a c ti v e po w e r i s a s i g n ed calcula ti o n . i f t h e phas e dif f er en ce b e tw e e n t h e c u r r en t a nd v o l t ag e wa v e fo r m a r e m o r e t h an 90, t h e a v era g e p o wer b e com e s n e g a t i v e . n e g a t i v e po w e r in d i ca t e s th a t en e r g y i s b e i n g p l aced b a ck o n t h e grid . the ad e7758 has a sig n det e c t io n cir c ui tr y f o r ac ti v e p o w e r calc u l a t io n. th e re vp ap b i t (bi t 17) in t h e i n t e r r u p t s t a t us r e g i s t er is s et if t h e a v er a g e p o wer f r o m a n y o n e o f t h e phas es c h a n g e s sig n . th e p h as e s m o ni t o r e d a r e s e le c t e d b y terms e l b i t s in t h e c o mpmo d e r e g i s t er (s e e t a b l e 1 7 ). the term sel b i t s a r e als o us e d t o s e le c t w h ich phas es a r e i n cl ude d in t h e apcf an d v a rcf p u ls e o u t p u t s. i f t h e re vp a p b i t is s et in t h e mas k r e g i st er , t h e ir q log i c o u t p u t g o es ac ti v e lo w (s ee t h e ad e7758 i n t e r r u p ts s e c t io n). n o t e t h a t this b i t is s et w h en ev er t h er e a r e sig n cha n g e s, i . e . , t h e re vp ap b i t is s et fo r b o t h a p o s i t i ve - t o - ne g a t i ve cha n ge or a ne g a t i ve - t o - p o s i t i ve change of t h e s i g n b i t. th e apcfnu m [1 5:13] indic a t e re v e rs e p o w e r on e a ch o f t h e i ndivi d u al phas es. bi t 15 wi l l b e s e t i f t h e sig n o f t h e p o w e r o n p h as e a is nega t i ve , bi t 14 fo r p h as e b , a nd b i t 13 fo r p h as e c. = output lpf2 data power average ? ? ? ? ? ? + 12 2 1 register gain watt the o u t p u t is s c aled b y ?50% w h en t h e wa t t ga in r e g i s t er s co n t en ts a r e s et t o 0x800 a n d t h e o u t p u t is in cr e a s e d b y +50% b y wr i t ing 0x7ff t o t h e wa t t ga in r e g i s t er . this r e g i s t er can b e us e d t o cal i b r a te t h e ac t i ve p o wer (o r en erg y ) calc u l a t io n i n t h e ad e7758 f o r eac h p h as e . active power offset c a libration the ad e7758 a l s o in co r p o r a t es a wa t t o f fs et r e g i s t er o n each phas e (a w a t t os, b w a t t o s, a nd cw a t to s). th e s e a r e sig n e d t w os com p l e me n t , 1 2 -b i t reg i s ters t h a t ar e u s e d t o re mo v e o f fs ets in t h e ac t i v e p o wer calc u l a t io ns. an o f fs et ma y exis t i n t h e p o w e r c a lc u l a t ion d u e t o cr os s t al k b e tw e e n cha nne ls o n t h e pcb o r in t h e chi p i t s e lf. th e of fs et calib r a t io n al lo ws t h e con - t e n t s o f th e a c ti v e po w e r r e gi s t e r t o be m a i n ta i n ed a t 0 wh e n n o po w e r is b e in g c o n s u m e d . o n e ls b in t h e ac t i ve p o w e r o f fs et r e g i s t er is e q uiv a len t t o 1 / 16 lsb in t h e ac t i v e p o w e r m u l t i p l i er outpu t . a t f u l l - s ca le i n p u t, if t h e o u t p ut f r om t h e m u l t i p li er i s 0 x ccc c d (838 ,861d), t h en 1 l s b in t h e lp f2 o u t p u t is eq ui valen t t o 0.0075% o f measur em en t er r o r a t ?60 db do wn o f f u l l s c ale a t c u r r en t cha n ne l. a t ?60 db do w n o n f u l l s c ale (t he in p u t sig n al l e ve l is 1/1000 o f f u l l -s cale s i g n al in p u ts), t h e a v era g e w o r d va l u e f r o m lp f2 is 838.861 (838,861/1,000). one ls b is eq ui va len t t o 1/838.861 /16 100% = 0.0075% o f the m e as ur e d v a l u e . th e a c ti v e p o w e r o f fs et r e gis t e r h a s a co rr ect i o n r e s o l u tio n eq ual t o 0.0075% a t ? 60 db . no-load threshold the ad e7758 has a n in t e r n al no-lo a d thr e sh old o n each p h as e. the n o -lo a d t h resh old can b e a c t i va te d b y s e t t i n g t h e n o lo a d b i t (b i t 7) o f th e co mp m o d e r e gi s t e r . i f t h e acti v e po w e r falls b e lo w 0.005 % of f u l l -s cale i n p u t, t h e e n erg y is n o t acc u m u la t e d i n tha t p h a s e . a s s t a t ed , t h e a v era g e m u l t i p li e r o u t p u t wi t h full- scale i n p u t i s 0xccccd . th e r ef o r e , i f th e a v e r a g e m u l t i p li e r o u t p u t fal l s b e lo w 0x2a, t h e p o w e r is n o t acc u m u l a t e d t o a v o i d cr e e p in t h e meter . the n o -lo a d t h r e s h ol d is i m plem e n t e d o n ly on t h e a c t i v e e n e r g y a c c u m u l a t i on . t h e re a c t i ve an d a p p a re n t en erg i es do n o t ha v e t h e n o -lo a d t h r e sh old o p t i o n . activ e ene r gy c a lc ulation a s s t a t e d ea r l ier , p o w e r is def i ned as t h e ra t e o f en er g y f l o w . this r e la t i o n s h i p ca n b e exp r es s e d ma t h ema t ical l y a s e q ua t i o n 7. dt denergy power = ( 7 ) co n v e r s e l y , en e r g y is g i v e n as t h e in t e g r al o f p o w e r . () dt t p energy = ( 8 )
ade7758 rev. a | page 32 of 68 04443-a - 039 awg[11:0] wdiv[7:0] digital integrator multiplier i v hpf current signal?i(t) 0x2851ec 0x00 0xd7ae14 voltage signal ?v(t) 0x2852 000x 0xd7ae + + + + lpf2 % sign 2 6 2 0 2 ?1 2 ?2 2 ?3 2 ?4 wattos[11:0] watthr[15:0] 15 0 40 0 total active power is accumulated (integrated) in the active energy register time (nt) t average power signal ?p 0xccccd 0x00000 f i gur e 6 6 . ade7 758 a c ti v e ener gy a c c u m u l a t i o n the ad e7758 ac hiev es t h e in t e g r a t io n o f t h e ac ti v e p o w e r sig n al b y con t in uo us l y acc u m u l a tin g t h e ac ti ve p o w e r sig n al in t h e in t e r n al 4 1 -b i t e n erg y r e g i s t ers. th e wa t t - h r r e g i s t ers (a w a t t h r , b w a t th r , an d cw a t th r) r e p r es en t t h e u p p e r 16 b i t s o f t h es e i n t e r n a l reg i s ters . thi s di s c re t e t i me ac c u m u l a t i on o r s u m m a ti o n is eq ui v a len t t o in t e gra t i o n i n co n t in uo us tim e . e q ua t i on 9 exp r es s e s t h e r e la t i on s h i p () () ? ? ? ? ? ? = = = 0 n 0 t t nt p lim dt t p energy ( 9 ) w h er e n is t h e dis c r e t e time s a m p le n u m b er a n d t is t h e s a m p le pe ri od . f i gur e 66 sh o w s a sig n al p a t h o f this ener g y acc u m u l a tio n . th e a v er a g e ac t i ve p o wer s i g n al is con t i n u o usly adde d t o t h e i n ter nal a c ti v e en e r g y r e gi s t e r . t h i s ad di ti o n i s a s i g n e d o p e r a t i o n . n e g a t i v e en e r g y i s s u b t ra c t ed f r o m t h e a c ti v e en e r g y r e gi s t e r . n o t e t h e val u es s h o w n i n f i gur e 65 a r e t h e n o minal f u l l -s cale val u es, i . e ., t h e vol t a g e an d c u r r en t i n p u ts a t t h e co r r es p o n d in g phas e a r e a t t h ei r f u l l -s cale i n p u t le v e l. th e a v er a g e ac t i ve p o we r is divide d b y t h e co n t e n t o f t h e wa t t d i vider r e g i ster b e fo r e i t is adde d t o t h e cor r es p o n d in g wa t t - h r acc u m u la t i o n r e g i s t ers. w h en t h e va l u e in t h e wd iv[7 :0] r e g i s t er is 0 o r 1, ac t i v e po w e r i s a c cum u l a t e d w i th o u t d i v i s i o n . w d i v i s a n 8 - b i t un s i gn ed r e gi s t e r th a t i s use f ul t o le n g th e n t h e tim e i t tak e s b e fo r e t h e wa t t - h r acc u m u l a t i on r e g i s t ers o v er f l o w . f i g u r e 67 s h o w s th e en e r g y a c cum u la ti o n f o r full- s cale si gn als (sin us o i dal) o n t h e analog in p u ts. th e t h r e e displa ye d c u r v es s h o w t h e m i nim u m t i m e i t tak e s f o r th e w a t t -h r a c cum u la ti o n r e g i s t er t o o v er f l o w w h e n t h e w a t t gain r e g i s t er o f t h e co r - r e s p o ndin g p h as e eq uals t o 0x7ff , 0x000, a n d 0x800. th e wa t t ga in r e g i s ters a r e us e d t o ca r r y o u t a p o w e r cal i b r a t ion i n t h e ad e7758. a s sh o w n, t h e fas t est in t e g r a t io n tim e o c c u rs w h en t h e wa t t gain r e g i s t ers a r e s et t o maxim u m f u l l s c ale , i . e ., 0x7ff . this is t h e t i m e i t tak e s bef o r e o v er f l o w ca n be s c aled b y wr i t in g to t h e wdiv r e g i ster a nd t h er e f o r e ca n b e i n cr e a s e d b y a maxim u m fac t or o f 255. n o t e t h a t t h e ac t i v e e n erg y r e g i s t er co n t e n t ca n r o l l o v er t o f u l l - s c ale nega ti ve (0x8000) a n d con t in ue in cr easing in val u e w h en th e a c ti v e po w e r i s pos i ti v e (see f i g u r e 66). c o n v e r s e l y , i f t h e a c ti v e p o w e r i s n e ga ti v e , t h e en e r g y r e gi s t e r w o uld un d e r f l o w t o f ull-scale posi ti v e (0x7fff) a n d co n t in ue d e cr easin g in val u e . b y s e t t i n g t h e a e hf b i t (b i t 0) o f t h e i n ter r u p t mas k r e g i st er , th e ad e7758 c a n b e co nf igur e d t o is s u e an in ter r u p t ( ir q ) w h en b i t 14 o f a n y o n e o f t h e t h r e e wa t t - h r acc u m u l a t i o n r e g i s t ers has cha n g e d , i ndi ca t i ng t h a t t h e acc u m u l a t i o n r e g i s ter is half f u l l (p osi t i v e o r nega ti ve). s e t t in g t h e rstread b i t (b i t 6 ) o f t h e l c y m o d e r e g i s t er ena b les a r e ad- w i t h-r e s et fo r t h e wa t t - h r acc u m u l a t i o n r e g i s ters, i . e ., t h e reg i s t ers a r e r e s et t o 0 a f t e r a r e ad op era t io n. 04443-a - 040 contents of watthr a ccumulation registe r 0x7fff 0x3fff 0x0000 0xc000 0x8000 time (sec) 0.13 0.52 0.79 1.05 1.31 1.58 watt gain = 0x7ff watt gain = 0000 watt gain = 0800 f i gure 6 7 . ener gy r e gi st er rol l - o v er tim e f o r f u ll -s c a l e p o w e r ( m ini m u m and m a x i mum p o wer g a in )
ade7758 rev. a | page 33 of 68 inte gra t ion time unde r stea dy load t h e d i sc r e t e t i m e sa m p l e p e ri od (t ) f o r th e ac cu m u la ti o n r e g i s t er is 0.4 s (4/clki n ). w i th f u l l -s c a le sin u s o ida l sig n als o n t h e a n alog in p u ts an d the wa t t ga in r e g i s ters s et t o 0x000, t h e a v e r a g e w o r d v a l u e f r o m ea c h lp f2 i s 0xccccd (see f i g u r e 64 an d f i g u re 6 6 ) . t h e m a x i m u m v a lu e w h i c h c a n b e s t ore d i n t h e w a tt - h r a c c u m u l a t i o n re g i st e r b e f ore it o v e r f l o w s i s 2 15 ? 1 o r 0x7fff . b e ca us e t h e a v er a g e wo r d val u e is adde d t o t h e i n ter nal re g i ste r , w h i c h c a n s t ore 2 40 ? 1 o r 0xf f , fff f , ffff bef o r e i t o v e r f l o w s , th e in t e gra t i o n t i m e un de r th ese co n d i ti o n s w i t h w d iv = 0 is cal c u l a t e d as second 0.524 s 0.4 0xccccd ffff ffff, 0xff, = = time whe n wd iv is s et t o a val u e di f f er en t f r o m 0, th e t i m e b e fo r e o v er f l o w is s c a l e d acco r d in g l y as sho w n in e q ua t i on 10. ( ) [ 0 : 7 wdiv 0 wdiv time time = = ] ( 1 0 ) energy a c cumulation mode the ac t i ve p o wer acc u m u l a te d in e a ch w a t t -hr acc u m u la t i on r e g i s t er (a w a t t hr , b w a t thr , o r cw a t thr) dep e n d s on th e co n f i g ura t i o n o f th e co ns el b i t s i n t h e c o mp m o d e r e g i s t er (b i t 0 and b i t 1). the dif f er en t co nf igura t io n s a r e des c r i b e d i n t a b l e 6. tab l e 6. i n p u ts to watt-hr accumulation registers co sel1 0 awatt h r b w atthr cwatt h r 00 va ia vb ib vc ic 01 va (ia C ib) 0 vc (ic C ib ) 10 va (ia C ib) 0 vc ic 11 reserved reserved reserved n o t e t h a t t h e con t e n ts o f t h e w a t t - h r acc u m u la t i o n r e g i s t ers a r e a f f e ct ed b y bo th th e curr en t g a in r e gi s t e r (i g a in ) a n d t h e w a t t ga in r e g i s ter o f t h e co r r es p o ndi n g phas e . i g ai n sh o u ld n o t b e used w h en us i n g m o d e 0 o f co n s el , co mpm o d e [0: 1 ]. d e p e nding o n t h e p o ly phas e m e t e r s e r v ic e , t h e a p p r o p r i a t e fo r m u l a sh o u ld b e ch os e n t o cal c u l a te t h e ac t i v e en erg y . th e am er ic a n ans i c12.10 s t anda rd def i n e s t h e dif f er en t co nf igura t io n s o f t h e m e t e r . t a b l e 7 d e scri bes wh i c h m o de sh o u ld be ch osen in t h e s e dif f er en t co nf ig ura t io n s . table 7. meter form configuration asi meter form cosel d termsel d 5s/13s 3-wire delta 0 3, 5, or 6 6s/14s 4-wire wye 1 7 8s/15s 4-wire delta 2 7 9s/16s 4-wire wye 0 7 dif f er en t ga in c a lib r a t ion p a ra m e t e rs a r e o f fer e d i n t h e ad e7758 t o co v e r th e cal i b r a t io n o f th e met e r in dif f er en t co nf igura t io n s . i t s h o u l d be n o ted tha t in co ns el m o de 0 d t h e igai n an d w g ai n r e g i st e r s ha v e t h e s a me ef fe c t o n t h e en d r e s u l t . h o w e v e r , c h a n gin g i g a i n also c h a n g e s all o t h e r calc u l a t io n s t h a t us e t h e c u r r en t wa vefo r m . i n o t h e r w o r d s, chang i ng i g ai n changes t h e a c t i ve, re ac t i ve, and a p p a ren t en erg y , as we l l as t h e rms c u r r en t c a lc u l a t io n r e s u l t s. active power frequency output p i n 1 (apcf) of th e ad e7758 p r o v ides f r eq uen c y o u t p u t f o r th e t o tal a c ti v e po w e r . a f t e r i n i t ial cali b r a t i o n d u rin g ma n u fac t ur i n g, t h e ma n u f a c t ur er o r en d c u s t om er wi l l o f t e n v e r i f i es t h e energ y m e t e r c a l i b r a t io n. o n e con v e n ien t w a y t o v e r i f y t h e m eter cal i b r a t io n is fo r t h e man u fac t u r er t o p r o v ide a n o u t p u t f r eq ue n c y th a t i s p r o p o r ti o n al t o th e e n e r g y o r a c ti v e p o w e r u n der ste a d y lo ad co nd i t i o n s . this o u t p ut f r e q uen c y ca n p r o v id e a si m p l e , sin g le - w ir e , op t i ca l l y is ol a t e d in t e r f ace t o ext e r n al cal i b r a t io n e q u i pm en t. f i gur e 68 i l l u s t ra t e s t h e e n erg y - t o -f r e q u en c y co n v ersio n in the ad e7758. 04443-0-041 input to bwatth r register input to awatthr register input to cwatth r register dfc apcf apcfnum[11:0] apcfden[11:0] + + + 4 f i gure 68. a d e 7 7 5 8 ac tive p o w e r f r eq uenc y o u tput a di g i t a l - to - f re qu e n c y c o n v e r te r ( d f c ) i s u s e d to ge ne r a te t h e apcf p u ls e o u t p u t f r o m t h e t o t a l ac t i v e p o w e r . terms e l b i ts (b i t 2 t o bi t 4) o f t h e co mpm o d e reg i s ter can b e u s e d t o s e l e c t w h ich phas es t o in cl ude in t h e to t a l p o w e r calc u l a t ion. s e t t i n g b i t 2 , bi t 3 , and b i t 4 i n cludes t h e i n pu t t o t h e a w a t th r , b w a t thr , and cw a t thr reg i s t ers i n t h e to t a l ac t i ve p o w e r calcula t i o n. th e t o tal a c ti v e po w e r i s s i gn e d a d d i ti o n . h o w e v e r , se t t i n g t h e a b s b i t (b i t 5) i n th e co mp m o d e r e gi s t e r e n a b le s t h e a b s o l u t e o n ly m o de , t h a t is, o n ly t h e abs o l u te val u e o f t h e ac t i v e p o w e r is co n s ider e d . the out p ut f r om t h e d f c is div i de d do w n b y a p a ir o f f r e q ue n c y d i v i s i on re g i s t e r s b e f ore s e nd i n g to t h e a p c f pu l s e output . n a m e ly , apcf d e n/ap cfnu m p u ls es a r e n e e d e d a t t h e d f c output b e f ore t h e a p c f pi n output s a pu l s e. u n d e r ste a dy l o a d c o n d i t i o n s , t h e output f r e q u e nc y i s d i re c t ly prop or t i on a l to t h e t o t a l ac t i v e p o wer . the p u ls e wi d t h o f a p cf is 64 clkin if apcfnu m and apcfd e n a r e b o t h e q ual. i f apcfd e n is g r e a t e r t h a n ap cfnu m, t h e pu ls e wi d t h de p e n d s on apcfd e n. the p u ls e w i d t h in t h is cas e is t (apcfd en/2), w h er e t is t h e p e r i o d o f t h e ap cf p u ls e a nd a p cfd e n/2 is r o u n d e d t o t h e n e a r est w h ole n u m b er . an excep t io n t o t h i s is when t h e p e r i o d is g r ea t e r than 180 m s . i n this cas e , t h e p u ls e wid t h is f i xed a t 90 m s .
ade7758 rev. a | page 34 of 68 the maxim u m o u t p u t f r eq uen c y (apcfnu m = 0x00 a n d apcfd e n = 0 x 00) wi t h f u l l -s cale ac sig n als on o n e phas e is a p p r o x ima t e l y 16 kh z. the ad e7758 in co r p o r a t es two r e g i s t ers t o s e t th e f r eq uen c y o f apcf (apcfnu m [11:0] a nd apcfd e n[11:0]). th es e a r e u n s i gn ed 12 - b i t r e g i s t e r s th a t ca n be us ed t o a d j u s t th e fr eq ue n c y o f apcf b y 1/2 12 t o 1 wi th a s t ep o f 1/2 12 . f o r ex am pl e, i f t h e o u t p u t f r eq uen c y is 1.562 kh z, while t h e co n t en ts o f cfd i v a r e 0 (0x000), th en th e ou t p u t f r eq uen c y ca n be s e t t o 6.103 h z b y wr i t in g 0xff t o t h e cfd e n r e g i s t er . i f 0 is wr i t ten t o a n y o f t h e f r e q uen c y divisio n reg i s t ers, t h e divid e r w o u l d us e 1 i n t h e f r e q uen c y divisio n . i n ad di t i o n , t h e ra t i o apcfnu m/ apcfd e n s h o u l d b e s e t no t g r e a t e r t h an one to e n su re prop e r op e r a t i o n . i n ot he r word s , t h e a p c f o u t p u t f r eq ue n c y ca n n o t b e h i g h e r th a n t h e f r eq ue n c y o n t h e df c out p ut . the o u t p u t f r e q uen c y has a sl ig h t r i p p le a t a f r e q uen c y e q u a l to t w ice t h e li n e f r e q uen c y . this is d u e t o i m p e r f e c t f i l t er in g o f t h e in s t an tan e o u s p o w e r sign al t o gen e ra t e t h e activ e po w e r sign al (see t h e a c t i v e p o w e r calcu l a t io n secti o n ) . eq ua ti o n 5 gi v e s a n exp r es sio n fo r t h e in s t a n t a n e o u s p o w e r sig n al. this is f i l t er e d b y lpf2, w h ich ha s a ma g n i t ude resp o n s e g i ven b y e q ua t i on 11. () 2 2 8 1 1 f f h + = ( 1 1 ) the ac t i ve p o w e r sig n al ( o ut p u t o f t h e l p f2) c a n b e re w r i t ten as () () ( t f 4 f irms vrms irms vrms t p 1 2 2 1 cos 8 2 1 ? ? ? ? ? ? ? ? ? ? ? ? ? ? + = ) (12) w h er e f 1 is the lin e f r eq uen c y , f o r exa m p l e , 60 h z . f rom e q u a t i on 1 2 , () () () t f 4 f t f irms vrms t irms vrms t e 1 2 2 1 1 cos 8 2 1 4 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? + = (13) f rom e q u a t i on 1 3 , it c a n b e s e e n t h a t t h er e is a smal l r i p p le i n t h e en erg y calc u l a t io n d u e t o t h e sin(2t ) co m p o n en t. f i gur e 69 sho w s t h is . the r i p p l e ge t s larger wi t h l a rger l o ads. c h o o s i ng a lo w e r o u t p u t f r eq uen c y f o r apc f d u r i n g cali b r a t io n b y usin g a la rg e apc f d e n val u e a n d k e ep i n g apcfnu m r e la t i v e ly smal l ca n sig n i f ica n t l y r e d u ce t h e r i p p le . als o , a v era g in g t h e o u t p u t fr eq ue n c y o v e r a lo n g e r pe ri od o f ti m e a c h i ev e s th e sa m e r e s u l t s . 04443-0-042 ? e(t) t vlt vi sin(4 f 1 t) 4 f 1 1 + 2 2f 1 8 f i g u re 69. o u t p ut f r equ e nc y r i p p le line cycl e acti ve energ y accumulation mo de the ad e7758 is desig n ed wi th a s p ec ial energ y acc u m u l a tion m o de t h a t si m p lif i es t h e cal i b r a t io n p r o c es s. b y usin g t h e o n - c h i p zer o -cr o s s in g detec t io n, t h e ad e7758 u p da t e s t h e wa t t -hr acc u m u la t i on r e g i s t ers a f t e r an in teg er n u m b er o f zer o cr os sin g s (f i g ur e 70). th e lin e a c t i v e en er g y a c cum u la ti o n m o d e f o r w a t t - hr acc u m u l a tio n is ac tiva t e d b y s e t t in g t h e l w a t t b i t (b i t 0) o f t h e lcy c mo de r e g i s t er . th e to t a l e n erg y o v er a n i n t e g e r n u mb e r of h a l f - l i n e c y cl es is w r i t t e n t o t h e w a t t - h r acc u m u l a t i on r e g i s t ers a f t e r t h e linec y c n u m b er o f zer o cr os sin g s ha v e been d e t e ct e d . w h e n us in g t h e li n e c y c l e a c cum u la ti o n m o d e , th e rs tread b i t (b i t 6) o f th e l c y c m o d e r e g i s t er sh o u ld b e s et t o l o g i c 0. 04443- 0- 043 zxsel0* zero-crossing detection (phase a) zxsel1* zero-crossing detection (phase b) zxsel2* zero-crossing detection (phase c) * zxsel[0:2] are bits 3 to 5 in the lcycmode registe r calibration control linecyc[15:0] wattos[11:0] wg[11:0] wdiv[7:0] + + % + + watthr[15:0] accumulate active power for linecyc number of zero-crossings; watt-hr accumulation registers are updated once every linecyc number of zero-crossings active power 15 0 40 0 f i gure 70. ade 7 7 5 8 li ne c y c l e ac tive e n er gy ac cu m u l a ti on m o de
ade7758 rev. a | page 35 of 68 p h as e a , p h as e b , a nd p h as e c zer o cr os sin g s a r e , r e s p e c t i ve ly , in cl ude d w h e n co un t i n g t h e n u m b er o f half-l ine c y cles b y s e t t in g zx s e l[0:2] b i t s (b i t 3 to b i t 5) in t h e lcy c m o d e re g i ste r . a n y c o mbi n a t i o n of t h e z e ro c r o s s i ng s f rom a l l t h re e p h a s e s ca n b e used f o r co un tin g th e z e r o cr os s i n g . o n l y o n e p h a s e sh o u ld be se lect e d a t a t i m e f o r in c l usi o n in t h e z e r o cr os sin g s co un t d u r i n g cal i b r a t io n (s ee t h e cal i b r a t ion s e c t ion) . the n u m b er o f zer o cr os sin g s is s p e c if ie d b y t h e linecy c r e g i s t er . line c y c is a n u n sig n e d 16-b i t r e g i s t e r . the ad e775 8 ca n acc u m u la te ac ti v e p o w e r f o r u p t o 65535 co m b in e d zer o cr os sin g s. n o t e t h a t t h e in t e r n al zer o cr os sin g c o un t e r is alwa ys ac t i v e . b y s e t t i n g t h e l w a t t b i t , t h e f i rs t e n erg y acc u m u l a t i o n r e s u l t is t h er efor e in co r r e c t. w r i t in g t o t h e li necy c r e g i s ter w h en t h e l w a t t b i t is s et r e s ets t h e zer o -cr o s s in g co u n t e r , t h us en s u r i n g t h a t t h e f i rs t e n erg y acc u m u l a t i o n r e su l t is acc u ra te . a t t h e e n d o f a n en erg y cal i b r a t i o n c y cle , t h e le ner g y b i t (b i t 12) in t h e st a t us r e g i s t er is s et. i f t h e co r r es p o ndin g mas k b i t in t h e i n t e r r u p t mask reg i s t er is enab le d , t h e ir q o u t p u t also g o e s a c ti v e lo w ; th us, th e ir q ca n als o b e us ed t o sig n a l t h e e nd o f a ca l i b r a t io n. b e ca us e ac t i v e p o w e r is i n t e g r a t e d o n an i n teg e r n u m b er o f hal f line c y cles in t h i s m o de , t h e s i n u s o ida l co m p onen t is r e d u c e d to 0. this el imina tes an y r i pple i n t h e e n erg y c a l c u l a t ion. th erefo r e, t o tal en e r g y a c cum u la t e d us i n g th e lin e - c y c le a ccum u la ti o n mo d e i s () t irms vrms t e = ( 1 4 ) w h er e t i s th e a ccum u la ti o n tim e . n o te t h a t l i ne c y cle ac t i v e e n erg y ac c u m u l a t i on u s es t h e s a me s i gn al pa th a s th e a c ti v e e n e r g y a c cum u la t i o n . t h e l s b s i z e o f t h es e t w o met h o d s is e q ui v a len t . u s in g t h e li n e c y cle acc u m u la - t i on t o calcu l a t e t h e kw h / l s b co n s ta n t r e s u l t s in a v a l u e tha t ca n b e a ppl ie d t o t h e w a t t h r reg i st ers w h en t h e l i ne ac c u m u l a t i on m o d e i s n o t se l e ct ed (s ee th e c a li b r a t i o n s e cti o n ) . reactive power calculation a loa d th a t co n t a i n s a r e acti v e e l e m en t (in d uct o r o r ca pa ci t o r) p r o d uces a phas e dif f er en ce b e t w e e n t h e a p plie d ac v o l t a g e an d t h e r e s u l t in g c u r r en t. th e p o w e r as s o ci a t e d wi t h r e ac t i v e e l em e n t s i s called r e a c ti v e po w e r a n d i t s uni t i s v a r . r e a c t i v e p o w e r is def i n e d as t h e p r o d uc t o f t h e v o l t a g e and c u r r en t wa v e fo r m s w h e n o n e o f t h e s e sig n als is p h as e shif t e d b y 90. e q ua t i on 17 g i ves a n exp r es sio n fo r t h e in st a n t a n e o u s r e ac t i ve p o w e r sig n al in a n ac sys t e m w h e n t h e phas e o f t h e c u r r en t cha nnel is shif te d b y +90. () ( = C sin 2 t v t v ) ( 1 5 ) () () () ? ? ? ? ? ? + = = 2 sin 2 sin 2 t i t i t i t i (16) w h er e v = r m s v o l t a g e , i = r m s c u r r en t, = t o t a l phas e shif t ca us e d b y t h e r e ac t i v e e l e m en ts in t h e lo ad . th e n t h e in st an t a n e o u s re ac t i v e p o w e r q ( t ) ca n b e exp r es s e d as ( ) ( ) ( ) () ? ? ? ? ? ? ? ? ? ? ? ? = = 2 C C 2 cos C 2 C C cos t vi vi t q t i t v t q wh e r e ( ) t i is t h e c u r r en t wa vefo r m phas e s h if t e d b y 90. n o te th a t q ( t ) ca n b e r e wr i t ten as ( ) ( )( ) + = C 2 sin sin t i v vi t q ( 1 7 ) the a v er a g e r e ac t i v e p o w e r o v e r a n in t e g r al n u m b er o f li n e cy c l e s ( n ) is g i v e n b y t h e exp r es sio n in e q u a t i on 18. () ( ) = = nt i v dt t q nt q 0 sin 1 ( 1 8 ) w h er e t is t h e p e r i o d o f t h e line c y c l e . q is r e fer r e d t o as t h e a v er a g e r e ac t i v e p o w e r . the ins t an t a n e ous r e act i v e po w e r si gnal q ( t ) i s ge ne r a te d b y m u lt i p l y i n g t h e volt ag e sig n als a nd t h e 90 phas e- s h if te d c u r r en t i n e a ch phas e . the dc com p onen t o f t h e i n s t an t a n e o u s r e ac t i v e p o w e r sig n al i n e a ch phas e (a, b , a nd c) is t h e n ext r ac t e d b y a lo w-p a s s f i l t er to ob t a i n t h e a v er ag e r e ac t i v e p o wer info r m a t io n o n e a ch phas e . this p r o c ess is i l l u st ra t e d in f i g u r e 71. the r e ac t i v e p o wer o f e a ch phas e is ac c u m u l a t e d i n t h e co r r es p o nding 16-b i t v a r - h o ur r e g i s t er (a v a rhr , b v a r hr , o r cv arh r ). th e i n p u t t o e a ch r e ac t i ve e n erg y r e g i ster ca n b e cha n ge d de p e nd in g o n t h e a c cum u la ti o n m o d e s e t t i n g (s ee t a b l e 17). t h e f r e q u e nc y re sp ons e of t h e l p f i n t h e re a c t i ve p o we r s i g n a l p a t h is i d en t i ca l t o t h a t o f t h e l p f2 us e d i n t h e a v era g e ac t i v e p o w e r calc u l a t io n (see f i gur e 65). 04443- 0- 044 v rms i rms sin( ) 00000h current i(t) = 2 irms sin( t) voltage v(t) = 2 vrms sin( t? ) instantaneous reactive power signal q(t) = vrms irms sin( ) + vrms irms sin(2 t+ ) average reactive power signal = v rms i rms sin( ) f i gure 71. r e ac t i ve p o w e r ca lc ul ati o n the lo w-p a s s f i l t er is n o nidea l s o th e r e ac t i v e p o w e r sig n al has s o me r i p p le . th is r i p p le is sin u s o ida l an d has a f r e q uen c y e q ua l
ade7758 rev. a | page 36 of 68 t o t w ice t h e li n e f r e q uen c y . b e c a us e t h e r i p p l e is sin u s o i d al in na t u r e , i t is r e m o v e d when t h e r e ac t i v e p o wer sig n al is in teg ra t e d o v er t i m e t o c a lc u l a te t h e r e ac t i ve e n erg y . the phas e - s h if t f i l ter has C 9 0 phas e shi f t w h e n t h e i n teg r a t o r i s enab l e d and +9 0 phas e shif t w h en t h e i n teg r a t o r is dis a b l e d . i n addi t i on, t h e f i l ter has a non u ni t y ma g n i t u d e resp on s e . b e c a u s e t h e phas e - shif t f i lt er has a la rge a t t e n u a t ion a t hi g h f r e q u e n c y , t h e r e act i ve po w e r is p r ima r i l y f o r t h e calcu l a t io n a t lin e f r eq uen c y . the ef fe c t o f ha r m o n ics is la rge l y ig no r e d i n t h e re ac t i ve p o w e r ca lc u l a t ion. n o te t h a t b e c a us e of t h e mag n i t ude cha r ac t e r i st i c o f t h e phas e shi f t i ng f i l ter , t h e lsb w e ig h t o f t h e re ac t i v e p o w e r calcu l a t i o n i s s l igh t l y di f f e r en t f r o m tha t o f t h e acti v e p o w e r ca lc u l a t ion ( s e e t h e e n erg y r e g i sters s c a l ing s e c t ion) . reactive power g a in c a libration the a v er a g e r e ac t i v e p o w e r f r o m t h e l p f o u t p u t in e a ch phas e c a n b e s c a l e d by 5 0 % by w r i t i n g t o t h e p h a s e s v a r g a i n r e g i s t er (a v a rg, b v ar g, o r cv ar g). th e v a r ga i n r e g i s t ers are t w o s c o m p l e me n t , s i g n e d re g i ste r s , a n d h a v e a re s o lut i on of 0.024%/ls b . the f u n c t i o n o f t h e v a r ga in r e g i s t ers is exp r es s e d b e lo w . = power reactive average ? ? ? ? ? ? + 12 2 1 register gain var output lpf2 the o u t p u t is s c ale d b y C50% w h e n t h e v a r ga in r e g i st ers co n t en ts a r e s et t o 0x800 a n d t h e o u t p u t is in cr e a s e d b y +50% b y wr i t ing 0x7ff t o t h e v a r ga in r e g i st er . this r e g i s t er can b e us e d t o cal i b r a te t h e r e ac t i ve p o w e r (o r en erg y ) calc u l a t io n i n th e ad e7758 f o r eac h p h as e . reactive power offset calibration the ad e7758 in co r p o r a t es a v a r o f fs et r e g i s ter o n eac h p h as e (a v a r o s, b v ar os, a nd cv a r os). th es e a r e sig n e d t w os co m p le m e n t , 12 -b i t r e g i s t ers t h a t a r e us e d t o r e m o ve o f fs ets in t h e r e ac t i v e p o w e r calc u l a t io n s . an o f fs et ma y exis t in t h e p o w e r calc u l a t i o n d u e t o cr os s t al k b e tw e e n channe ls o n t h e pcb o r in t h e chi p i t s e lf. th e of fs et calib r a t io n al lo ws t h e co n t en t s o f t h e r e a c ti v e po w e r r e gi s t e r t o be m a i n ta in ed a t 0 w h en n o r e ac t i ve p o w e r is b e i n g co n s u m e d . th e o f fs et r e g i s t ers re s o lut i on i s t h e s a me a s t h e a c t i ve p o we r of f s e t re g i ste r s ( s e e t h e a p p a r e n t p o w e r of fs et c a l i b r a t io n s e c t ion). sign of r e acti ve pow er c a lc ulation n o t e t h a t t h e a v era g e r e ac t i ve p o w e r is a sig n e d calc u l a t io n. a s s t a t e d p r e v io us ly , t h e phas e s h if t f i l t er has C90 phas e s h if t w h e n t h e in t e g r a t o r is ena b le d and +9 0 phas e s h if t w h e n t h e in teg ra t o r is dis a b l e d . t a b l e 8 summa r i zes t h e r e la t i o n shi p b e tw e e n t h e phas e dif f er en ce b etw e e n t h e v o l t a g e an d t h e c u r r en t an d t h e sig n o f t h e r e s u lt in g v a r calc u l a t io n. the ad e7758 has a sig n det e c t io n cir c ui t f o r the r e ac ti v e p o w e r calc u l a t io n. th e re vp rp b i t (b i t 18) in t h e i n t e r r u p t s t a t us r e g i s t er is s et if t h e a v er a g e r e ac t i v e p o wer f r o m a n y o n e o f t h e phas es cha n g e s. the phas es m o ni t o r e d a r e s e le c t e d b y terms e l b i ts i n t h e c o mpmo d e r e g i s t er (s e e t a b l e 17). i f t h e re vprp b i t is s et i n t h e mas k r e g i st er , t h e ir q log i c o u t p u t g o es ac t i v e lo w (s e e t h e ad e77 58 i n t e r r u p ts s e c t io n). n o t e t h a t t h is b i t is s e t w h ene v er t h er e is a sig n cha n g e , i . e., t h e b i t is s e t f o r bo th a pos i t i v e - t o-n e g a ti v e ch a n g e o r a n e g a ti v e - t o- pos i ti v e cha n g e o f t h e si g n b i t. table 8. sign o f reactive pow e r calculation 1 integrator sign of reactive power between 0 to +9 0 off positive between ?90 to 0 off negative between 0 to +90 on positive between ?90 to 0 on negative _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ___ __ __ __ __ __ __ __ __ __ __ __ __ 1 i s de fi n e d a s t h e ph a s e a n gle of t h e vo lt a g e si gn a l m i n us t h e curr en t s i gnal , i.e., is p o s i tive if the l o ad is in d u ctive and negative if the load i s capaciti ve. reactive energy ca lcu l a t ion reac t i v e en er g y is def i n e d as t h e in t e g r al o f r e ac ti v e p o w e r . () dt t q energy reactive = ( 1 9 ) s i mi la r t o ac ti v e p o w e r , t h e ade7758 ac hiev es th e in t e g r a t io n o f th e r e ac t i v e p o w e r sig n al b y co n t in uo us l y acc u m u l a ting t h e r e ac t i v e p o w e r sig n al i n t h e in te r n al 41-b i t acc u m u l a t i o n r e g i s t ers. th e v a r - hr r e g i s t ers (a v a rhr , b v arh r , an d cv arhr) r e p r es en t t h e u p p e r 16 b i t s o f t h es e i n t e r n al re g i ste r s . t h i s d i s c re te t i m e a c c u m u l a t i on or su m m a t i o n i s eq ui valen t t o in t e g r a t ion in co n t in uo us time . e q ua t i o n 20 exp r es s e s t h e r e la t i on s h i p () () ? ? ? ? ? ? = = = 0 n t t nt q lim dt t q energy reactive 0 (20) w h er e n is t h e dis c r e t e time s a m p le n u m b er a n d t is t h e s a m p le pe ri od . f i gur e 72 s h o w s th e s i gn al pa th o f th e r e a c ti v e e n e r g y a c cum u la - t i o n . th e a v era g e r e ac t i v e p o w e r sig n al is co n t i n uo us ly adde d to th e i n t e rn al r e acti v e en e r g y r e gi s t e r . t h i s add i tio n i s a s i g n e d o p e r a t io n . n e ga ti v e en e r g y is s u b t ra c t ed f r o m t h e r e a c ti v e en e r g y r e g i s t er . th e a v era g e r e ac t i ve p o w e r is divi de d b y t h e co n t e n t of t h e v a r divider r e g i s t er b e fo r e t h e y a r e adde d to t h e co r r e- s p on din g v a r - hr acc u m u l a t i on r e g i s t ers. w h en t h e v a l u e i n t h e v a rd iv[7: 0 ] r e g i s t er is 0 o r 1, t h e r e ac t i v e p o w e r is acc u m u la te d wi t h o u t an y divisi o n . v a rd iv is a n 8- b i t un s i gn ed r e gi s t e r th a t i s use f ul t o le n g th e n t h e tim e i t tak e s b e fo r e t h e v a r - hr acc u m u l a t i on r e g i s t ers o v er f l o w . simi la r t o r e ac t i v e p o w e r , t h e fas t es t in t e g r a t ion t i me o c c u rs w h en t h e v a r ga in r e g i s ters a r e s et t o maxim u m f u l l s c ale, i . e., 0 x 7 f f . th e tim e i t tak e s be f o r e o v e r f l o w ca n be s c al ed b y w r i t in g to t h e v a rdiv r e g i ster a nd t h e r efo r e i t ca n b e i n cr e a s e d b y a maxim u m fac t or o f 255.
ade7758 rev. a | page 37 of 68 04443-a - 045 varg[11:0] vardiv[7:0] 90 phase shifting filter multiplier i v hpf current signal ? i(t) 0x2851ec 0x00 0xd7ae14 voltage signal?v(t) 0x2852 0x00 0xd7ae + + + + lpf2 % sign 2 6 2 0 2 ?1 2 ?2 2 ?3 2 ?4 varos[11:0] varhr[15:0] 15 0 40 0 total reactive power is accumulated (integrated) in the var-hr accumulation registers 2 f i gur e 7 2 . ade7 758 rea c ti v e ene r gy a c c u m u l a t i o n energy a c cumulation mode w h en o v er f l o w o c c u rs, t h e v a r - hr acc u m u la t i o n r e g i s t ers co n t en t ca n r o llo v e r t o ful l -s cale n e ga ti v e (0x8000) a n d co n t in ue in cr e a s i n g i n va l u e w h en t h e r e ac t i v e p o w e r is p o si t i v e . co n - v e r s e l y , i f th e r e a c t i v e po w e r i s n e g a ti v e th e v a r - h r a c cum u la t i o n r e gis t er s co n ten t ca n r o ll o v er to f u ll-scale posi ti v e (0x7fff) a nd co n t in ue de cr e a sin g i n va l u e. the r e ac t i ve p o w e r acc u m u la te d i n e a ch v a r - hr acc u m u l a t i on r e g i s t er (a v a r h r , b v arh r , o r cv arhr) dep e n d s o n t h e co nf igura t io n of t h e c o ns el b i ts i n t h e c o m p mo d e r e g i s t er (b i t 0 a nd b i t 1). the dif f er en t co nf igura t io n s a r e des c r i b e d i n t a b l e 9. table 9. i nputs to var-hr accumulation registers b y s e t t i n g t h e r e hf b i t (b i t 1) o f t h e mas k r e g i s t er , t h e ad e7758 ca n b e co nf igur ed t o is s u e a n in t e r r u p t ( ir q ) when bit 1 4 of an y o n e of t h e t h re e v a r - h r a c c u m u l a t i on re g i ste r s h a s c h a n g e d , in d i ca tin g th a t t h e a c cum u la t i o n r e gi s t e r i s h a lf f u ll (p osi t i v e o r n e ga ti v e ). co nsel[1, 0] avarhr b varhr cvarhr 00 va ia vb ib vc ic 01 va(ia C ib) 0 vc (ic C ib) 10 va(ia C ib) 0 vc ic 11 reserved reserved reserved not e tha t ia /ib /ic ar e the cu r r en t phase shif t e d cu r r en t wa v e f o r m . s e t t in g t h e rstread b i t (b i t 6 ) o f t h e l c y m o d e r e g i s t er ena b les a r e ad- w i t h-r e s et fo r t h e v a r - hr ac c u m u l a t i o n r e g i s t ers, i . e ., t h e r e g i s t ers a r e r e s et t o 0 a f t e r a re ad o p er a t ion. the co n t en ts o f t h e v a r - hr acc u m u l a t i o n r e g i st ers a r e a f fe c t e d b y b o t h t h e c u r r en t ga i n r e g i s ter (i gain) an d t h e v a r ga i n r e g i s t er o f t h e c o r r es p o n d in g phas e . inte gra t ion time unde r stea dy load t h e d i sc r e t e t i m e sa m p l e p e ri od (t ) f o r th e ac cu m u la ti o n r e g i s t er is 0.4 s (4/clki n ). w i th f u l l -s c a le sin u s o ida l sig n als o n t h e a n alog i n p u ts, an d a 90 phas e dif f er en ce b e tw e e n t h e v o l t a g e an d t h e c u r r en t sig n al (t h e la rg es t p o s s ib le r e ac t i v e p o w e r), an d t h e v a r ga in r e g i st ers s et t o 0x000, th e a v er a g e w o r d v a l u e f r o m ea ch l p f2 i s 0xcccc d . th e m a xi m u m val u e t h a t c a n b e s t ore d i n t h e re a c t i v e e n e r g y re g i ste r b e f ore it ov e r f l ow s i s 2 15 ? 1 o r 0x7fff . a s t h e a v er a g e w o r d val u e is f i rs t adde d to t h e in ter na l r e g i ster , w h ich c a n sto r e 2 40 ? 1 o r 0xff , ffff , ffff bef o r e i t o v er f l o w s, th e in t e gra t io n tim e un d e r t h es e co ndi tion s wi t h v a rd iv = 0 is calc u l a t e d as re ac tive powe r freq ue ncy ou tpu t p i n 17 (v ar cf ) o f th e ad e77 58 p r o v ides f r eq uen c y o u t p u t f o r th e t o tal r e a c ti v e po w e r . s i m i la r t o a p c f , th i s p i n p r o v i d e s a n o u t p u t fr eq u e n c y t h a t i s d i r e ct l y p r o p o r t i o n a l t o th e t o ta l r e a c ti v e p o w e r . th e p u ls e wid t h o f v a rp cf i s 64 clkin if v a r c fnu m a nd v a r c fd e n a r e bo th e q ua l . i f v a r c fd e n is g r ea t e r than v a r c fnu m , t h e p u ls e w i d t h dep e n d s on v a r c fd en. th e p u ls e wi d t h i n t h is cas e is t (v ar cfd e n/2) , w h er e t is t h e p e r i o d o f t h e v a r c f p u ls e and v a r c fd en/2 is r o u n d e d t o t h e ne a r es t w h ole n u m b er . an e x cep t io n t o t h is is w h en t h e p e r i o d is g r ea t e r tha n 180 m s . i n this cas e , t h e p u ls e wid t h is f i xed a t 90 m s . second 0.5243 s 0.4 0xccccd ffff ffff, 0xff, = = w h en v a rd iv is s et t o a val u e dif f er en t f r o m 0, t h e t i m e bef o r e o v er f l o w a r e s c ale d acco r d ing l y as sh o w n in e q ua tio n 21. () = = ( 2 1 ) a di g i t a l - to - f re qu e n c y c o n v e r te r ( d f c ) i s u s e d to ge ne r a te t h e v a r c f p u ls e o u t p u t f r o m t h e t o t a l r e ac ti v e p o w e r . th e t e rms e l b i t s (b i t 2 t o b i t 4) o f th e co mp m o d e r e gi s t e r ca n be used t o se lect wh i c h p h a s e s t o b e in c l ud ed in t h e t o tal r e a c ti v e po w e r calc u l a t io n. s e t t in g b i t 2, bi t 3, a nd b i t 4 i n cl udes t h e in p u t t o th e a v a r hr , b v a r h r , a n d cv a r h r r e gi s t er s i n t h e t o tal a c ti v e p o w e r calcula t i o n . th e t o tal r e a c ti v e po w e r i s s i gn e d addi t i on. h o we v e r , s e t t in g t h e sa v a r b i t (b i t 6) in t h e c o mpmo d e r e g i s t er enab les abs o l u t e v a l u e ca lc u l a t ion.
ade7758 rev. a | page 38 of 68 de t in g apcf = watts if watt < 0 i f th e a c ti v e po w e r o f th a t p h a s e i s pos i ti v e , n o c h a n g e i s m a t o th e s i g n o f t h e r e ac ti v e p o w e r . h o w e v e r , if t h e sig n o f t h e a c ti v e p o w e r i s n e ga ti v e i n th a t p h a s e , t h e s i g n o f i t s r e a c ti v e p o w e r is in v e r s e d b e f o r e s u mmin g a nd cr ea t i n g v a r c f p u ls es. this m o d e sh o u ld b e us e d in con j u n c t io n w i t h t h e abs o l u te val u e m o d e f o r acti v e p o w e r (b i t 5 in t h e co mpm o d e r e g i s t er) fo r apcf p u ls es. t a b l e 10 sh o w s t h e e f fe c t o f s e t t h e abs and sa v a r b i ts o f t h e c o mpmo d e r e g i s t er . the ef fe c t s o f s e t t i n g t h e ab s and sa v a r b i t s o f t h e c o m p mode r e g i ste r re su l t s a s fol l o w s w h e n ab s = 1 a nd sa v a r = 1 : if watt > 0 varcf = va r a p c f = | w a t t s | varcf = -va r 04443-0-046 input to bvarh r register input to avarhr register input to cvarh r register + + + input to bvahr register input to avahr register input to cvahr register + + + 0 1 varcf varcfnum[11:0] varcfden[11:0] dfc vacf bit (bit 7) of wavmode register 4 f i gure 73. a d e 7 7 5 8 r e ac tive p o wer f r equenc y o u tput the out p ut e q ue n c y c y co n v ersio n in t h e t p o we r . e i s f r e q u e nc y output are s i m i l a r to t h a t f r om t h e d f c is div i de d do w n b y a p a ir o f f r d i v i s i on re g i s t e r s b e f ore s e nd i n g to t h e a p c f pu l s e output . n a m e ly , v a r c fd en/v ar cf nu m p u ls es a r e n e e d e d a t t h e df c output b e f ore t h e v a r c f pi n output s a pu l s e. u n d e r s t ead y loa d co n d i ti o n s , t h e o u t p u t f r eq ue n c y i s d i r e ctl y prop or t i on a l to t h e tot a l re a c t i v e p o we r . f i gur e 68 i l l u s t ra t e s t h e e n erg y - t o-f r e q uen ad e7758. n o te tha t t h e in p u t to th e d f c c a n be s e lec t ed bet w een t h e t o t a l r e a c ti v e po w e r a n d t o tal a p pa r e n t po w e r . ther efo r e , t h e v a r c f p i n can ou t p ut f r e q uen c y t h a t is prop or t i on a l to t h e tot a l re a c t i v e p o we r or tot a l a p p a re n the s e le c t ion is made b y s e t t i n g t h e v a cf b i t ( b i t 7) in t h e w a v m o d e r e gi s t e r . s e t t in g thi s b i t t o l o gi c h i gh sw i t c h e s t h in p u t t o t h e t o t a l a p p a r e n t p o w e r . the def a u l t v a l u e o f t h is b i t i s l o g i c l o w . t h e r e f ore, t h e d e f a u l t output f rom t h e v a rc f pi n i s th e t o tal r e a c ti v e po w e r . a l l ot he r op e r at i o ns of t h o f th e a c t i v e p o w e r f r eq ue n c y o u t p u t (see t h e a c ti v e p o w e r fr e q u e n c y o u t p ut s e c t i o n ) . line cycl e reactive energy accu mu la tion mod e t h e lin e c y c l e r e a c ti v e en e r g y accum u la ti o n m o d e i s a c ti v a t e d b y s e t t i n g t h e l v ar b i t (b i t 1) i n t h e l c y c mo d e r e g i s t er . th e t o t a l r e ac t i ve e n erg y acc u m u la te d o v er a n in t e ger n u m b er o f z e ro c r o s s i ng s i s w r itte n to t h e v a r - h r a c c u m u l a t i on re g i ste r s a f t e r th e l i n e cy c n u m b e r o f ze r o cr os s i n g s h a s been d e t e ct e d . the o p era t io n of t h is m o de is si mi la r t o w a t t -hr acc u m u l a t i on (s e e t h e l i ne c y cle a c t i v e e n erg y a c c u m u l a t i on m o de s e c t ion). w h e n us in g t h e li n e c y c l e a c cum u la ti o n m o d e , th e r s t r ead b i t (b i t 6) o f th e l c y c m o d e r e g i s t er sh o u ld b e s et t o log i c 0. apparent power calculation a p p a r e n t p o wer is def i n e d as t h e a m pli t ude o f t h e v e c t o r s u m of th e a c ti v e a n d r e a c ti v e po w e r s . f i g u r e 74 s h o w s wh a t i s t y p i cally r e f e rr ed t o a s th e po w e r tria n g le . 04443-0-047 re activ e p o we r active power apparent power f i gure 74. p o wer t r iangle ther e a r e tw o w a ys t o calc u l a t e a p p a r e n t p o w e r , na me ly t h e a r i t hm et i c al a p p r o a ch o r t h e ve c t o r ial met h o d . the a r i t hmet i c al m e t h o d us es t h e p r o d uc t o f t h e v o l t a g e r m s v a lue a nd c u r r en t rm s v a l u e t o calcul a t e a p pa r e n t po w e r . eq ua ti o n 2 2 d e sc r i be s th e a r i t hm eti cal a p p r oa c h m a th e m a t icall y . s = vrm s irms ( 2 2 ) w h er e s i s th e a p pa r e n t po w e r , a n d vrm s and irms a r e t h e r m s v o l t a g e and c u r r en t, r e s p e c t i v e ly . t h e ve c t or i a l m e t h o d u s e s t h e s q u a re ro ot of t h e su m of t h e ac t i v e and r e ac t i v e p o w e r , a f t e r t h e tw o a r e i ndivi d u al ly s q ua r e d . eq ua t i o n 2 3 s h o w s th e c a l c ula t i o n us ed i n th e v e ct o r i a l ap p r o a c h . 2 2 q p s + = ( 2 3 ) w h er e s i s th e a p pa r e n t po w e r , p is th e ac t i v e p o w e r , a nd q is th e r e acti v e po w e r .
ade7758 rev. a | page 39 of 68 f o r a p u r e sin u s o ida l sys t em, t h e tw o a p p r o a ches s h o u l d yi e l d t h e sa m e r e s u l t . th e a p p a r e n t en e r g y calcu l a t i o n in t h e ad e7758 us es t h e a r i t hmet ical a p p r o a ch. h o w e v e r , t h e li n e c y cle en erg y acc u m u la tion m o de in t h e ad e7758 ena b les en erg y acc u m u la - t i o n b e tw e e n ac t i v e an d r e ac t i ve en erg i es o v er a sy n c hr o n o u s pe ri od o f tim e , th us t h e v e ct o r ial m e t h o d ca n b e ea s i l y i m p l em en t e d in th e e x t e rn al m c u (see t h e lin e c y c l e a c ti v e en er g y a c c u m u la tio n m o de s e c t io n). n o t e t h a t a p p a r e n t p o w e r is al wa ys p o si ti v e r e g a r d les s o f th e dir e c t ion o f t h e ac t i v e o r r e ac t i ve en erg y f l o w s. the r m s va l u e of t h e c u r r en t an d v o l t a g e i n e a ch phas e is m u l t i p l i e d t o p r o d uce t h e a p p a r e n t p o w e r o f t h e co r r es p o n d in g phas e. the o u t p u t f r o m th e m u l t i p li e r i s th en lo w - pa s s f i l t e r ed t o o b ta in t h e a v e r age a p p a re n t p o we r . t h e f r e q u e nc y re sp ons e of t h e l p f i n th e a p pa r e n t po w e r s i gn al pa th i s i d e n ti cal t o tha t o f th e l p f2 us e d i n t h e a v era g e ac t i ve p o we r calc u l a t io n (s e e f i gur e 65). apparent power g a in c a libration n o t e t h a t t h e a v era g e ac t i ve p o w e r r e s u l t f r o m t h e lp f o u t p u t in each p h as e can b e s c aled b y 50% b y wr i t in g t o th e p h as e s v a gain r e g i ster (a v a g, b v a g , o r cv a g ). th e v a g a in r e gi s t e r s a r e tw os c o m p l e m e n t , s i gn e d r e gi s t e r s a n d h a v e a r e s o l u tio n o f 0.024%/ls b . th e f u n c tion o f the v a gain r e g i s t ers is exp r es s e d b e lo w ma t h ema t i c al ly . = power apparent average ? ? ? ? ? ? + 12 2 register vagain output lpf 1 2 the o u t p u t is s c ale d b y C50% w h e n t h e v a r ga in r e g i st ers co n t en ts a r e s et t o 0x800 a n d t h e o u t p u t is in cr e a s e d b y +50% b y wr i t ing 0x7ff t o t h e wa t t ga in r e g i s t er . this r e g i s t er can b e us e d t o cal i b r a te t h e a p p a r e n t p o w e r (o r en erg y ) calc u l a t io n i n th e ad e7758 f o r eac h p h as e . apparent power o ffset calibration e a ch r m s m e asur em e n t i n cl u d es a n o f fs et co m p en s a t i o n r e g i s t er t o cal i b r a t e an d e l imina t e t h e dc com p on e n t i n t h e r m s val u e (s e e t h e c u r r en t rms c a l c u l a t ion an d v o l t a g e c h ann e l rms c a lc u l a t io n s e c t ion s ). th e v o l t a g e an d c u r r en t r m s va l u es a r e th en m u l t i p li ed t o g e t h e r in t h e a p pa r e n t po w e r s i gn al p r o c es sin g . a s n o addi t i o n al o f fs ets a r e cr e a t e d in t h e m u l t i p li ca t i o n of t h e r m s val u es , t h er e is n o sp e c if ic o f fs et co m p ens a t i on i n t h e a p p a r e n t p o w e r sig n al p r o c es sing. th e o f fs et co m p en s a t i o n o f t h e a p p a r e n t p o wer m e as ur em e n t in e a ch phas e sh ou ld b e don e b y ca l i b r a t in g e a ch indivi d u a l r m s m e as ur em e n t (s ee th e c a li b r a t io n secti o n ) . appa rent ene r gy c a l c ul atio n a p p a r e n t en er g y is def i n e d as t h e in t e g r al o f a p p a r e n t p o w e r . a ppa r e n t e n er g y = s ( t ) dt (24) s i mi la r t o ac ti v e a nd r e ac ti v e energ y , th e ad e7 758 ac hiev es t h e in teg ra t i on o f t h e a p p a r e n t p o w e r sig n al b y con t i n uo us ly a c cu m u l a ti n g th e a p pa r e n t po w e r s i gn al in th e i n t e rn al 4 0 - b i t, un sig n e d acc u m u l a t i o n r e g i s ters. the v a - h r r e g i s t ers (a v a hr , b v ahr , an d c v ahr) r e p r es e n t t h e up p e r 16 b i t s o f t h e s e i n ter nal r e g i s ters. this dis c r e te t i me acc u m u l a t i o n o r s u mma t ion is eq ui valen t t o in teg ra tion in c o n t in uo us tim e . e q ua tion 25 b e lo w exp r es s e s t h e re l a t i o n s h i p () () ? ? ? ? ? ? = = = 0 n t nt s lim dt t s energy apparent 0 t (25) w h er e n is t h e dis c r e t e time s a m p le n u m b er a n d t is t h e s a m p le pe ri od . f i gur e 75 sh o w s t h e s i g n al p a t h o f t h e a p p a r e n t en erg y acc u m u - la t i on. t h e a p p a r e n t p o wer sig n a l is co n t i n uo usly adde d to t h e in t e r n al a p p a r e n t e n erg y r e g i s ter . the a v er a g e a p p a r e n t p o w e r is divide d b y t h e c o n t e n t o f t h e v a divi der r e g i s ter b e fo r e t h e y a r e adde d t o t h e co r r esp o ndi n g v a - h r acc u m u l a t i on r e g i st ers. w h e n th e val u e in t h e v a d i v[7:0] r e g i s t er is 0 o r 1, a p p a r e n t p o wer is acc u m u la te d wi t h o u t an y divisi o n . v a d i v is an 8-b i t u n sig n e d r e gi s t e r th a t i s use f ul t o le n g t h en t h e tim e i t tak e s be f o r e th e v a - h r a c c u m u l a t i on re g i ste r s ove r f l o w . simi la r to ac t i v e o r r e ac t i v e p o wer acc u m u l a t i on, t h e fa stest in teg ra t i on t i me o c c u rs w h en t h e v a gain r e g i s t ers a r e s e t t o maxim u m f u l l s c ale , i.e ., 0x7ff . w h en o v er f l o w o c c u rs, t h e v a - h r a c c u m u l a t i on re g i ste r s c o n t e n t s c a n ro l l o v e r to 0 an d co n t in ue in cr easin g in val u e . b y s e t t in g t h e v a ehf b i t (b i t 2) o f th e mask r e g i s t er , th e ad e7758 ca n be co nf igured t o is s u e an in t e r r u p t ( ir q ) w h e n t h e ms b o f an y o n e o f t h e t h re e v a -hr acc u m u la t i on r e g i s t ers has c h an g e d , indica t i n g t h a t t h e acc u m u la tion r e g i s t er is half f u l l . s e t t in g t h e rstread b i t (b i t 6 ) o f t h e l c y m o d e r e g i s t er ena b les a r e ad- w i t h-r e s et fo r t h e v a -hr acc u m u l a t i o n r e g i s ters, i . e ., t h e reg i s t ers a r e r e s et t o 0 a f t e r a r e ad op era t io n. inte gra t ion time unde r stea dy load t h e d i sc r e t e t i m e sa m p l e p e ri od ( t ) f o r th e accum u la ti o n r e g i s t er is 0.4 s (4/clki n ). w i th f u l l -s c a le , 60 h z sin u s o idal sig n als o n t h e analog in p u ts and t h e v a gai n r e g i s t ers s e t t o 0x000, th e a v erag e w o r d val u e f r o m eac h lp f2 is 0xb9954. the m a xi m u m val u e th a t ca n be s t o r ed i n th e a p pa r e n t en e r g y re g i ste r b e f ore it o v e r f l o w s i s 2 16 ? 1 o r 0xffff . a s t h e a v era g e w o r d val u e is f i rs t adde d t o t h e i n t e r n al r e g i st er , w h ich can s t o r e 2 41 ? 1 o r 0x1f f , ffff , ffff bef o r e i t o v er f l o w s, th e in t e gra t io n t i m e un d e r th e s e c o n d i ti o n s w i th v a d i v = 0 i s c a l c ula t ed a s second 1.157 s 0.4 0xb9954 ffff ffff, 0x1ff, = = time w h en v a d i v i s s et t o a val u e dif f er en t f r o m 0, t h e t i m e b e fo r e o v er f l o w is s c a l e d acco r d in g l y as sho w n in e q ua t i on 26. ( ) vadiv 0 vadiv time time = = (26)
ade7758 rev. a | page 40 of 68 04443-a - 048 voltage rms signal 0x174bac 60hz 0x0 0x17f263 50hz 0x0 current rms signal 0x1c82b 0x00 multiplier irms v rms vag[11:0] vadiv[7:0] + + lpf2 % varhr[15:0] 15 0 40 0 apparent power is accumulated (integrated) in the va-hr accumulation registers f i gur e 7 5 . ade7 758 a p par e nt ene r gy a c c u m u l a t i o n table 10. i nput s to va-hr accumulation reg i sters co nsel[1, 0] ava hr b vahr cvahr 00 varms ia rms vbrms ibrms vcrms i c rms 01 varms ia rms ibrms vcrms varms + 2 vcrms i c rms 10 varms ia rms vbrms ibrms vcrms i c rms 1 1 r e s e r v e d r e s e r v e d r e s e r v e d note: varm s/vbrm s/vcrm s a r e t h e rm s vo lt a g e wa ve form , a n d iarm s/ibrm s/icrm s are the rms v a l u e s of the curre nt wave f o rm. energy a c cumulation mode t h e a p pa r e n t p o w e r a c cu m u l a t e d in ea c h v a - h r a c cu m u la ti o n re g i ste r ( a v a h r , b v a h r , or c v a h r ) d e p e n d s on t h e c o n - f i gura t i o n o f t h e c o ns el b i ts in t h e c o mpmo d e r e g i s t er (b i t 0 a nd b i t 1). the dif f er en t co nf igura t io n s a r e des c r i b e d i n t a b l e 10. the co n t en ts o f t h e v a -hr acc u m u l a t i o n r e g i s ters a r e a f fe c t e d b y b o t h t h e ga i n r e g i s t ers fo r t h e c u r r en t (i ga in) a nd r m s v o l t a g e ga i n (v rmsgai n), as w e l l as t h e v a g a in r e g i st er o f t h e co r r es p o ndi n g phas e . i g ai n sh o u ld n o t b e us e d w h e n usin g co ns el m o de 0, co mpm o d e [0:1]. apparent power frequency out p ut pi n 1 7 ( v a r c f ) of t h e a d e 7 7 5 8 c a n prov i d e f r e q u e nc y output f o r th e t o tal a p p a r e n t p o wer . b y s e t t in g t h e v a cf b i t (b i t 7) o f t h e w a vmo d e r e g i s t er , t h is pin p r o v ides a n ou t p ut f r e q uen c y t h a t i s d i re c t ly prop or t i on a l to t h e to t a l a p p a re n t p o we r . a di g i t a l - to - f re qu e n c y c o n v e r te r ( d f c ) i s u s e d to ge ne r a te t h e pu l s e output f rom t h e to t a l app a re n t p o w e r . t h e t e r m se l bit s (b i t 2 t o b i t 4) o f th e co mpm o d e r e g i s t er can b e us ed t o s e le c t w h ich phas es t o i n cl ude i n t h e t o t a l p o w e r calc u l a t io n. s e t t in g b i t 2, b i t 3, a nd b i t 4 in cludes t h e i n p u t to t h e a v a h r , b v a h r , a n d cv a h r r e gi s t e r s i n t h e t o tal a c ti v e po w e r ca lc u l a t io n . a p a ir o f f r e q uen c y divider r e g i ster s, na mely v a rcf d en and v a rcf n u m , ca n b e us e d to s c a l e t h e o u tp u t f r eq ue n c y o f th i s p i n . n o t e th a t e i t h e r v a r o r a p pa r e n t po w e r ca n be se lec t ed a t o n e tim e f o r th i s f r eq ue n c y o u t p u t (see t h e re ac t i v e p o wer f r e q uen c y o u t p u t s e c t ion). line cycl e apparent en ergy accumul a tion mode the li n e c y cle a p p a r e n t e n erg y acc u m u la t i on m o de is ac t i va t e d b y s e t t i n g t h e l v a b i t (b i t 2) i n t h e lcy c mod e r e g i s t er . th e tot a l a p p a re n t e n e r g y ac c u m u l a te d o v e r an i n te ge r n u mb e r of z e ro c r o s s i ng s i s w r itte n to t h e v a - h r a c c u m u l a t i on re g i ste r s a f t e r th e l i n e cy c n u m b e r o f ze r o cr os s i n g s h a s been d e t e ct e d . the o p era t io n of t h is m o de is si mi la r t o w a t t -hr acc u m u l a t i on (s e e t h e l i ne c y cle a c t i v e e n erg y a c c u m u l a t i on m o de s e c t ion). w h e n us in g t h e li n e c y c l e a c cum u la ti o n m o d e , th e r s t r ead b i t (b i t 6) o f th e l c y c m o d e r e g i s t er sh o u ld b e s et t o log i c 0. n o t e t h a t t h is m o de is esp e ci a l ly us ef u l w h en t h e us er ch o o s e s t o p e r f o r m t h e a p p a r e n t e n erg y calc u l a t io n usi n g t h e v e c t o r ial me t h o d . b y s e tt i n g l w a t t a n d l v a r bit s ( b it 0 a n d b i t 1 ) of t h e lcy c mo de r e g i s t er , t h e ac t i v e an d r e ac t i v e en erg i es a r e a c cum u la t e d o v e r th e sa m e pe riod o f tim e . th er e f o r e , th e m c u ca n p e rf o r m th e sq ua rin g o f t h e t w o t e rm s a n d t h en tak e t h e s q ua r e r o o t o f t h eir sum t o deter mi n e t h e a p p a r e n t e n erg y o v er th e s a m e pe ri o d o f ti m e .
ade7758 rev. a | page 41 of 68 energy registers scaling the ade7758 provides measurements of active, reactive, and apparent energies that use separate signal paths and filtering for calculation. the differences in the data paths can result in small differences in lsb weight between the active, reactive, and apparent energy registers. these measurements are internally compensated so that the scaling is nearly one to one. the relationship between the registers is shown in table 11. table 11. energy registers scaling frequency of 60 hz frequency of 50 hz integrator off var = 1.004 watt var = 1.0054 watt va = 1.00058 watt va = 1.0085 watt integrator on var = 1.0059 watt var = 1.0064 watt va = 1.00058 watt va = 1.00845 watt waveform sampling mode the waveform samples of the current and voltage waveform, as well as the active, reactive, and apparent power multiplier out- puts, can all be routed to the waveform register by setting the wavsel[2:0] bits (bit 2 to bit 4) in the wavmode register. the phase in which the samples are routed is set by setting the phsel[1:0] bits (bit 0 and bit 1) in the wavmode register. all energy calculation remains uninterrupted during waveform sampling. four output sample rates may be chosen by using bit 5 and bit 6 of the wavmode register (dtrt[1:0]). the output sample rate may be 26.0 ksps, 13.0 ksps, 6.5 ksps, or 3.3 ksps (see table 16). by setting the wsmp bit in the interrupt mask register to logic 1, the interrupt request output irq goes active low when a sample is available. the 24-bit waveform samples are transferred from the ade7758 one byte (8 bits) at a time, with the most significant byte shifted out first. the interrupt request output irq stays low until the interrupt routine reads the reset status register (see the ade7758 interrupts section). calibration a reference meter or an accurate source is required to calibrate the ade7758 energy meter. when using a reference meter, the ade7758 calibration output frequencies, apcf and varcf, are adjusted to match the frequency output of the reference meter under the same load conditions. each phase must be calibrated separately in this case. when using an accurate source for calibration, one can take advantage of the line cycle accu- mulation mode and calibrate the three phases simultaneously. there are two objectives in calibrating the meter: to establish the correct impulses/kw-hr constant on the pulse output and to obtain a constant that relates the lsbs in the energy and rms registers to watt/va/var hours, amps, or volts. additionally, calibration compensates for part-to-part variation in the meter design as well as phase shifts and offsets due to the current sensor and/or input networks. calibration using pulse output the ade7758 provides a pulsed output proportional to the active power accumulated by all three phases, called apcf. additionally, the varcf output is proportional to either the reactive energy or apparent energy accumulated by all three phases. the following section describes how to calibrate the gain, offset, and phase angle using the pulsed output information. the equations are based on the pulse output from the ade7758 (apcf or varcf) and the pulse output of the reference meter or cf expected . figure 76 shows a flow chart of how to calibrate the ade7758 using the pulse output. since the pulse outputs are proportional to the total energy in all three phases, each phase must be cali- brated individually. writing to the registers is fast in order to reconfigure the part for calibrating a different phase, therefore figure 76 shows a method that calibrates all phases at a given test condition before changing the test condition.
ade7758 rev. a | page 42 of 68 start calibrate irms offset calibrate vrms offset must be done before va gain calibration watt and va can be calibrated simutaneously @ pf = 1 because they have separate pulse outputs all phases va and watt gain cal? yes no set up pulse output for a, b, or c calibrate watt and va gain @ pf = 1 all phases gain cal var? yes no set up for phase a, b, or c calibrate var gain @ pf = 0 all phases ph cal? yes no set up pulse output for a, b, or c calibrate phase @ pf = 0.5 all ph var offset cal? yes no set up pulse output for a, b, and c calibrate var offset @ i min all ph watt offset cal? yes no set up pulse output for a, b, and c calibrate watt offset @ i min end 04443-0-098 f i g u re 76. ca lib r a t i on u s ing p u ls e o u t p ut gain cali brati o n using pulse output ga in cal i b r a t io n is us ed f o r m e t e r - t o -met er ga in ad j u s t men t , apcf o r v a r c f o u t p u t ra t e c a li b r a t io n, a nd det e r m inin g the w h /ls b , v a r h /ls b , and v a h/ls b co n s t a n t . th e r e g i st ers us e d fo r wa t t gai n c a l i b r a t io n ar e cfnu m (0x45), cfd e n (0x46), a nd xw g (0x2 a t o 0x2c). e q u a tio n s 32 thr o u g h 34 sh o w h o w t h es e r e g i s t ers af fe c t t h e w h / l sb co n s t a n t an d t h e apcf p u ls es. f o r calib r a t in g v a r ga in, t h e reg i s t ers in e q ua t i on s 32 thr o u g h 34 sh ou ld be r e place d b y v a r c fnu m (0x47), v a r c fd en (0 x48), a n d xv arg (0x2d t o 0x2f). f o r v a gain, they sh o u ld be r e p l ace d b y v a rcfnu m (0x47), v a r c fd en (0x48), a n d xv a g (0x30 t o 0x32). f i gur e 77 sh o w s t h e s t eps fo r ga in c a l i b r a t io n o f wa t t s, v a , o r v a r usin g t h e p u ls e o u t p u t s.
ade7758 rev. a | page 43 of 68 04443-0-099 start step 1 step 1a enable cf and varcf pulse outputs step 2 set gain registers: xwg, xvag, xvarg to logic 0 select va for varcf output cfnum/varcfnum set to calculate values? no yes all phases va and watt gain cal? yes no step 3 set up pulse output for phase a, b, or c step 5 set up system for i test , v nom pf = 1 step 6 measure % error for apcf and varcf step 7 calculate and write to xwg, xvag calculate wh/lsb and vah/lsb constants set cfnum/varcfnum and cfden/varcfden to calculated values step 4 end all phases var gain calibrated? yes no select var for varcf output step 3 set up pulse output for phase a, b, or c varcfnum/ varcfden set to calculated values? no yes step 5 set up system for i test , v nom pf = 0 step 6 measure % error for varcf step 7 calculate and write to xvarg calculate kvarh/lsb constant set varcfnum/varcfden to calculated values step 4 f i gur e 7 7 . gai n ca libr a tio n using p u l s e output s t ep 1: ena b le t h e p u ls e ou t p u t b y s e t t i n g b i t 2 o f t h e o p mo d e r e g i s t er (0x13) t o log i c 0. this b i t ena b les bo t h th e apcf an d va r c f p u l s e s . s t ep 1a: v a r and v a s h a r e t h e v a r c f p u ls e ou t p ut. w a vmo d e[7], a ddr es s (0x15) , s h o u l d b e s e t to ch o o s e b e t w een v a r o r v a p u lses o n t h e o u t p u t . s e t t i n g t h e b i t t o logic 1 s e le c t s v a . the de fa u l t i s l o g i c 0 o r v a rcf pu ls e out p u t . s t ep 2: en s u r e t h e x w g/xv arg/xv a g a r e s e t t o log i c 0. s t ep 3: dis a b l e t h e phas e b and p h as e c con t r i b u t i o n t o t h e apcf an d v a rcf p u ls es. this is do ne b y t h e t e rms e l[ 2:4] b i t s o f t h e c o m p mo d e r e g i s t er (0x16). s e t t in g b i t 2 t o l o g i c 1 and bi t 3 and bi t 4 t o l o g i c 0 al l o ws onl y p h as e a t o b e inc l u d e d in t h e p u ls e o u t p u t s. s t ep 4: s et apcfnu m(0x45) a nd apcfd e n(0x46) t o th e calc u l a t e d val u e t o p e r f o r m a co a r s e ad j u s t m e n t o n the i m p / k w h r a t i o . f o r va r / va c a l i b r a t i o n , v a r c f n u m ( 0 x 4 7 ) a nd v a r c fd e n (0x48) s h o u l d b e s et t o t h e cal c u l a t e d v a l u e . the p u ls e o u t p u t f r e q uen c y w i t h on e phas e a t f u l l -s cale in pu ts
ade7758 rev. a | page 44 of 68 is a p p r o x ima t e l y 16 kh z. a s a m p le s e t o f m e ters co u l d b e t e s t e d t o f i n d a m o r e e x ac t val u e o f t h e p u ls e o u t p u t a t f u l l s c ale . t o calc u l a t e d t h e val u es fo r apcfnu m/ apcf d e n a nd v a r c fnu m /v ar cfd e n us e t h e fol l o w in g fo r m u l as fullscale test fullscale nom nominal i i v v khz apcf = 16 (27) ( ) = cos 600 , 3 000 , 1 nom test expected v i mc apcf (28) ? ? ? ? ? ? = expected nominal apcf apcf int apcfden (29) w h er e mc i s th e m e t e r co n s ta n t , i tes t is t h e t e st c u r r en t, v no m is t h e n o minal v o lt a g e t h a t t h e me t e r is t e s t e d a t , and v f u llsc a le a nd i f u llsc a le a r e t h e val u es o f c u r r en t a nd v o l t ag e , w h ich co r r es p o n d t o t h e f u l l s c ale ad c in p u ts o f t h e ad e7758. is t h e an g l e b e tw e e n t h e c u r r en t and t h e v o l t a g e cha nne l, and t h e apcf exp e cted v a l u e i s eq ui vale n t t o th e r e f e r e n c e m e t e r o u t p u t un der the t e st c o n d i t io ns. t h e eq ua ti o n s f o r calcula t i n g t h e v a r c fn u m a n d v a r c fd en d u r i n g v a r c a l i b r a t io n a r e simi la r , wi th o n e excep t io n ( ) = sin 600 , 3 000 , 1 nom test expected v i mc varcf (30) b e ca us e t h e cf nu m an d cfd e n val u es ca n b e calc u l a t e d f r o m t h e m e t e r desig n , t h e s e va l u es ca n b e wr i t t e n t o t h e p a r t a u t o ma ticall y d u r i n g p r o d uct i o n calib r a t io n . s t ep 5: s et t h e tes t sys t em fo r i te s t , v no m , a n d t h e uni t y p o w e r f a ct o r . f o r v a r c a li b r a t i o n , th e po w e r f a ct o r s h o u l d be se t t o 0 in t h is st e p . f o r wa t t and v a , t h e uni t y p o w e r fa c t o r sh o u l d b e u s e d . v a g a in c a n b e c a li b r a t ed a t th e s a m e ti m e a s w g a i n beca u s e v a g a in c a n be c a l i b r a t ed a t th e u n i t y po w e r f a ct o r , a n d bo th p u lse o u t p u t s ca n be m e as ur ed s i m u l t a n eo us l y . h o w e v e r , w h en cal i b r a t in g v a g a in a t t h e s a me t i m e as w g ai n, t h e r m s o f fs ets sh o u ld b e cal i b r a t e d f i rs t (s e e t h e c a l i b r a t io n o f i r ms a nd v r m s of fs et s e c t io n ) . s t ep 6: m e as ur e t h e p e r c en t er r o r in t h e p u ls e ou t p ut, ap cf an d / or v a rc f , f rom t h e re f e re nc e m e te r : % 100 C % = ref ref cf cf apcf error (31) w h er e cf re f = apcf exp e cted = t h e pu l s e output of t h e re f e re n c e me te r . s t ep 7: c a lc u l a te xw g ad j u s t men t . o n e ls b cha n g e i n xw g (12 b i t s) c h a n g e s th e w a t t hr r e g i s t er b y 0.02 44% an d th er ef o r e apcf b y 0.0244%. the s a me r e l a tion shi p h o lds tr ue fo r v a rcf . = expected apcf [] [] [ ] ? ? ? ? ? ? + 12 2 0 : 11 1 0 : 11 0 : 11 xwg apcfden apcfnum apcf nominal (32) % 0244 . 0 % C erro r xwg = (33) w h en apcf is cal i b r a t e d , t h e x w a t thr reg i st ers ha v e t h e s a me wh/ l sb f rom me te r to me te r i f t h e me te r c o nst a n t and t h e apcf nu m /apcfd e n r a t i o r e ma in t h e s a m e . th e wh / l sb c o n s t a n t i s wdiv apcfnum apcfden c m lsb wh 1 000 , 1 4 1 = (34) s t ep 8: re t u r n to s t ep 2 t o cal i b r a t e p h as e b and p h as e c ga i n . examp l ewat t gain calibration of phase a using pulse o u tput fo r t h i s e x a m p l e , i tes t = 10 a, v no m = 220 v , v f u llsc a le = 500 v , i f u llsc a le = 130 a, mc = 3200 im p u ls es/kw h , po w e r f a c t o r = 1, a nd fr e q u e n c y = 50 h z . s et ap cfnu m ( 0x45) a n d ap cfd e n(0x46) t o th e calc u l a t e d va l u e to p e r f o r m a co a r s e a d j u st men t on t h e i m p/ kw h r a t i o . u s in g e q u a tio n s 27 thr o u g h 29. khz 542 . 0 130 10 500 220 16 = = khz apcf nominal () hz 96 . 1 0 cos 600 , 3 000 , 1 220 10 200 , 3 = = expected apcf 277 hz 96 . 1 hz 542 = ? ? ? ? ? ? ? ? = int apcfden wi t h i te s t , v no m , a nd t h e uni t y p o w e r fac t o r , t h e exa m ple ad e7758 met e r s h o w s 1.92 h z o n the p u ls e o u t p u t . this is e q ui vale n t t o a 2.04% er r o r f r o m t h e r e fer e n c e m e t e r val u e usin g e q ua t i o n 31. % 04 . 2 % 100 hz 96 . 1 h z 96 . 1 C h z 92 . 1 % = = error
ade7758 rev. a | page 45 of 68 the a w g val u e is calc u l a t e d t o be 84 d usin g e q ua t i o n 33, w h i c h me ans t h e v a lu e 0 x 3 f s h ou l d b e w r i tte n to a w g . 84 % 0244 . 0 % 04 . 2 ? = = xwg phase c a libration using pulse output the ad e7758 in c l udes a p h as e cal i b r a t io n r e g i st er o n each phas e t o co m p e n s a te fo r smal l phas e er r o r s. l a rg e phas e er r o r s s h o u l d b e co m p en s a t e d b y ad j u s t in g t h e a n t i ali a sin g f i l t ers. the ad e7758 s p h as e cal i b r a t ion is a tim e dela y wi t h dif f er en t w e i g h t s in t h e p o s i ti v e a n d n e g a ti v e di r e cti o n (s ee th e p h a s e c o m p en s a t i o n s e c t io n). b e ca us e a c u r r en t t r a n sfo r m e r is a s o ur ce o f phas e er r o r , a f i xe d n o mina l va l u e m a y b e de ci de d o n t o lo ad in t o t h e xp h c al r e g i s ters a t p o wer - u p . d u r i n g cal i b r a t io n, t h is val u e can b e ad j u s t e d fo r ct - t o-ct er r o r . f i gur e 78 sh o w s t h e s t eps in v o lv e d i n cal i b r a t i n g t h e phas e usin g t h e p u ls e o u t p ut. 04443-0-100 start all phases phase error calibrated? end yes no step 1 set up pulse output for phase a, b, or c and enable cf outputs step 2 set up system for i test , v nom , pf = 0.5 step 3 measure % error in apcf step 4 calculate phase error (degrees) step 5 period of system known? measure period using freq register no yes calculate and write to xphcal f i g u re 78. phas e cal i br at io n u s ing p u ls e o u t p ut s t ep 1: s t ep 1 and s t ep 3 f r o m t h e ga i n c a l i b r a t i o n sh o u ld b e r e p e a t ed t o co nf igur e the ad e7 758 p u ls e o u t p u t . s t ep 2: s et t h e tes t sys t em fo r i te s t , v no m , a n d 0.5 p o w e r fac t o r . s t ep 3: m e as ur e t h e p e r c en t er r o r in t h e p u ls e ou t p ut, ap cf , f rom t h e re f e re nc e m e te r u s i n g e q u a t i o n 3 1 . s t ep 4: c a lc u l a te t h e pha s e e r r o r in d e g r e e s usin g t h e fol l o w ing eq ua ti o n : () ? ? ? ? ? ? ? ? = 3 sin arc C error cf error phase (35) s t ep 5: c a lc u l a te xp h c a l () () = error phase s period s xphcal 1 360 4 . 2 C (36) i f i t is n o t k n o w n, t h e p e r i o d is a v a i la b l e in t h e ad e7758 s f r e q uen c y r e g i s t er , freq (0x10 ) . e q ua t i on 37 sh o w s ho w t o de te r m i n e t h e v a lu e t h a t ne e d s to b e w r it te n to xp h c al usin g t h e p e r i o d r e g i st er m e as ur e m en t. i n e q u a t i o n 3 7 , t h e 2.4 s is fo r phas e er r o r s t h a t a r e n e g a t i ve . f o r p o si t i v e phas e er r o r s, t h e 2.4 s is r e p l ace d b y 4.8 s (s e e th e p h as e c o m p en s a t i o n secti o n ) . [] 0 : 11 freq s s error xphcal ? ? ? ? ? ? ? ? = 360 4 . 2 6 . 9 3 sin arc 1 (37) examplepha s e calibration of phase a usi n g pulse output fo r t h i s e x a m p l e , i tes t = 10 a, v no m = 220 v , v f u llsc a le = 500 v , i f u llsc a le = 130 a, mc = 3200 im p u ls es/kw h , po w e r f a c t o r = 0.5 ind u c t iv e , and fre q u e n c y = 50 h z . wi t h i te s t , v no m , a nd 0.5 i n d u c t iv e p o w e r fac t o r , t h e exam ple ad e7758 met e r s h o w s 0.9821 h z on t h e p u ls e o u t p u t . this is eq ui valen t t o 0.215% er r o r f r o m t h e r e f e r e n c e m e t e r val u e usin g e q ua tion 31. the pha s e e r r o r in d e g r e e s using e q ua t i on 35 is ?0.07. () = ? ? ? ? ? ? ? ? = 07 . 0 C 3 00215 . 0 sin arc C error phase i f a t 50 h z t h e f r eq r e g i s t er = 2083d , t h e val u e tha t sh o u ld be wr i t t e n t o ap h c al (0x15) is 0x15 usin g e q ua t i o n 37. 21 66 . 20 2083 360 s 4 . 2 s 6 . 9 07 . 0 1 = = = aphcal power offset calibration us ing pulse out p ut p o we r of f s e t c a l i br a t i o n s h ou l d b e u s e d f o r out s t a n d i ng p e r f o r ma n c e o v er a wi de d y namic ra n g e (1,00 0 :1). c a l i b r a t ion o f t h e p o w e r o f fs et is don e a t o r clos e t o t h e mi nim u m c u r r en t wher e t h e des i r e d acc u rac y is r e q u ir ed . th e ad e7758 has p o w e r o f fs et r e g i s t ers fo r wa t t s and v a r (xw a t t os an d xv ar os). of fs ets i n t h e v a me as ur emen t a r e co m p ens a t e d b y ad j u s t i n g t h e r m s o f fs et r e g i s t e r s (s e e t h e c a l i b r a t io n o f irms a nd vrms of fs et s e c t ion). f i gu r e 79 s h o w s t h e s t eps t o cal i b r a t e t h e p o w e r o f fs ets usin g t h e p u ls e o u t p u t s.
ade7758 rev. a | page 46 of 68 04443-0-101 start step 1 enable cf output step 2 set offset registers xwattos, xvaros to logic 0 all phases watt offset and va offset calibrated? yes no all phases var offset calibrated? yes no set up apcf pulse output for phase a, b, or c step 3 set up system for i min , v nom , pf = 1 step 4 measure % error for apcf step 5 calculate and write to xwattos end set up varcf pulse output for phase a, b, or c step 3 set up system for i min , v nom , pf = 0 step 4 measure % error for varcf measure period using period register step 5 calculate and write to xvaros step 6. repeat step 3 to step 5 for xvaros f i g u re 79. o f f s et cal i br at io n u s ing p u ls e o u t p ut s t ep 1: re p e a t st ep 1 an d s t ep 3 f r o m t h e ga i n c a lib r a t ion t o co nf igur e th e ad e7758 p u ls e o u t p u t . s t ep 2: s et t h e xw a t t o s an d x v ar os r e g i s t ers t o l o g i c 0. s t ep 3: s et t h e tes t sys t em fo r i te s t = i min , v nom , a nd uni t y p o w e r fac t o r . f o r s t ep 6, s et t h e t e s t sy s t em fo r i te s t = i min , v no m , a n d z e ro - p owe r f a c t or . s t ep 4: m e as ur e t h e p e r c en t er r o r in t h e p u ls e ou t p ut, ap cf o r v a rc f , f rom t h e re f e re nc e me te r u s i n g e q u a t i on 3 1 . s t ep 5: calc u l a te xw a t t o s usin g e q ua tio n 38 (f o r xv ar os us e e q ua t i o n 39 ). = x wattos () apcfnum apcfden q apcf apcf expected error 4 2 % C (38) = x varos ( ) varcfnum varcfden q varcf varcf expected error 4 2 % C (39) w h er e q is def i n e d i n e q u a t i o n 40 a nd e q u a t i on 41. fo r x w a t t o s 4 1 2 1 4 25 = clki n q (40) fo r x v a r o s 4 1 4 202 2 1 4 24 ? ? ? ? ? ? = period clki n q (41) w h er e pe r i od is m e as ur ed f r o m t h e freq (0 x10) r e g i s t er . s t ep 6: rep e a t s t ep 3 t o s t ep 5 f o r xv ar os calib r a t io n.
ade7758 rev. a | page 47 of 68 exampleo ffs et calibration of phase a using pulse outp ut fo r t h i s e x a m p l e , i tes t = 50 ma, v no m = 220 v , v f u llsc a le = 500 v, i f u llsc a le = 130 a, mc = 3200 im p u ls es /kw h , po w e r f a c t o r = 1, fr e q u e n c y = 5 0 h z , and clk i n = 10 mh z. wi t h i te s t , v no m , a nd uni t y p o wer fac t o r , t h e exa m ple ad e775 8 m e t e r sh o w s 0.0 09773 h z o n t h e apcf p u ls e ou t p u t an d 0.009773 h z on th e v a r c f p u ls e o u t p u t . this is eq ui valen t t o 0.24% f o r th e wa t t meas ur em en t a nd 0.24 % f o r th e v a r m e as ur em en t. u s in g e q u a tio n s 38 thr o u g h 41, th e val u es 0xffb a nd 0x f f a sh ou ld b e wr i tten to a w a t tos ( 0 x 39) a n d v a ro s (0x3c ) , r e s p ecti v e l y . fo r a w a t t o s : 0186 . 0 4 1 2 1 4 6 10 25 = = e q fo r a v a r o s : 014 . 0 4 1 4 2083 202 2 1 4 6 10 24 = = e q () 5 . 4 C 1 227 0186 . 0 2 00975 . 0 0024 . 0 C 4 = = awattos () 6 C 1 227 014 . 0 2 00975 . 0 0024 . 0 C 4 = = avaros calibration us ing line a c cumul a tion l i n e c y cle acc u m u l a t i o n m o de co nf igur es t h e nine e n erg y r e g i s t ers s u ch t h a t t h e am o u n t o f en erg y acc u m u l a t e d o v er a n in teg er n u m b er o f half line c y cles a p p e a r s in t h e r e g i s t ers a f t e r t h e linec y c i n t e r r u p t. the b e n e f i t o f usin g t h is m o de is t h a t t h e s i n u s o i d al c o m p on en t o f t h e ac t i v e e n erg y is e l i m ina t e d . f i gur e 80 sh o w s a f l o w c h a r t o f h o w t o cal i b r a t e th e ad e7758 us i n g th e lin e accum u la ti o n m o d e . cali b r a t i o n o f all p h a s e s a n d en erg i es can b e do ne sim u lt an e o usly usin g t h is m o de to s a ve tim e d u r i n g c a l i b r a t io n. 04443-0-103 start cal irms offset cal vrms offset cal watt and va gain all phases @ pf = 1 cal var gain all phases @ pf = 0 calibrate phase all phases @ pf = 0.5 calibrate all phases watt offset @ i min and pf = 1 calibrate all phases var offsets @ i min and pf = 0 end f i g u re 80. ca lib r a t i on u s ing l i ne ac cu m u lat i on gain cali brati o n usin g line accumulation ga in cal i b r a t io n is us ed f o r m e t e r - t o -met er ga in ad j u s t men t , apcf o r v a r c f o u t p u t ra t e c a li b r a t io n, a nd det e r m inin g the w h /ls b , v a r h /ls b , and v a h/ls b co n s t a n t . s t ep 0: b e fo r e p e r f o r min g t h e g a in c a l i b r a t io n, t h e cfnu m/cfd e n (0x45/0x46) a nd v a r c f n u m /v ar cfd e n (0x47/0x48) val u es ca n b e s et to achie v e t h e cor r e c t im p u ls es /k w h , im p u ls es /kv a h, o r im p u ls es/ k v a r h usin g t h e s a m e m e th od o u t l i n ed i n s t e p 4 i n th e g a i n ca l i b r a t i o n u s i n g pulse ou t p u t se ctio n . th e calib r a t io n o f xw g/xv ar g/xv a g (0x2a th r o u gh 0x32) i s d o n e wi th t h e lin e accum u la ti o n m o d e . f i g u r e 81 s h o w s th e s t e p s i n v o l v ed in cali b r a t in g th e g a i n r e g i s t ers usin g t h e l i n e acc u m u l a t i o n m o de .
ade7758 rev. a | page 48 of 68 frequency known? no yes step 0 set cfnum/cfden and varcfnum/varcfden step 1 set xwg/xvar/xvag to logic 0 step 2 set lycmode register step 3 choose accumulation time (linecyc) step 4 set mask for lenergy interrupt step 5 set up system for i test , v nom , pf = 1 step 6 read frequency register step 7 reset status register step 8 read all xwatthr and xvahr after lenergy step 8a calculate xwg step 8b calculate xvag step 9 write to xwg and xvag calibrate watt and va @ pf = 1 04443-0-104 step 10 set up test system for i test , v nom , pf = 0 step 11 reset status register step 12 read all xvarhr after lenergy interrupt step 13 calculate xvarg step 14 write to xvarg step 15 calculate wh/lsb, vah/lsb, varh/lsb end f i gur e 8 1 . gai n ca libr a tio n using li ne a c c u m u l a t i o n s t ep 1: s et x w g, xv ar g, a nd x v a g t o log i c 0. s t ep 2: s et u p ad e7758 f o r lin e acc u m u l a tion b y wr i t in g 0x3f t o l c y c mo d e . this enab les t h e l i n e acc u m u l a t i o n m o de on th e xw a t thr , xv ahr , an d x v arhr (0x01 to 0x03) r e g i s t ers b y s e t t in g t h e l w a t t , l v ar , and l v a b i ts, l c y c m o d e [0:2] (0x17) , t o l o g i c 1. i t als o s e ts t h e zx s e l b i t s , lcy c mo d e [3 :5], t o l o g i c 1 t o ena b le t h e zer o -cr o s s in g de t e c t ion o n al l phas es fo r line acc u m u l a t i o n . a d di t i o n a l ly , t h e f r eq s e l b i t, l c y c m o d e [7], is s et t o log i c 0 s o tha t freq (0x10) s t o r e s th e lin e f r eq uen c y . w h e n us i n g th e lin e a c c u m u la ti o n m o de , t h e rs tread b i t o f l c y c m o d e s h o u l d be s e t t o 0 t o dis a b l e t h e re a d w i t h re s e t mo d e . s t ep 3: s et t h e n u m b er o f half-l i n e c y cles fo r lin e acc u m u la t i o n b y wr i t ing t o li necy c (0x1c). s t ep 4: s et t h e l e ner g y b i t, mas k [12] (0x1 8), t o l o g i c 1 t o ena b le t h e in t e r r u p t t h a t sig n als t h e e nd o f t h e l i ne c y cle acc u m u la t i on. s t ep 5: s et t h e tes t sys t em fo r i te s t , v no m , a n d u n i t y p o w e r fac t o r ( c a l ib r a te w a tt and v a si m u l t ane o usly a n d f i rst) . s t ep 6: re ad t h e freq (0x10) r e g i s t er if t h e f r e q uen c y is unk n o w n. s t ep 7: re s et t h e in t e r r u p t s t a t u s r e g i s t er b y r e adin g rst a tus (0x1a).
ade7758 rev. a | page 49 of 68 s t ep 8: re ad al l six xw a t thr (0x01 t o 0x03) a nd xv ahr (0x07 t o 0x09) e n erg y r e g i s t ers a f t e r th e lene r g y in t e r r u p t a nd s t o r e t h e va l u es. s t ep 8a: c a lc u l a t e t h e v a l u es t o b e wr i t t e n t o x w g r e g i st ers acco r d in g t o t h e fol l o w in g e q u a t i o n . () = 600 , 3 000 , 1 cos 4 2 12 test test v i mc xwg [] wdiv xwatthr accumtime 0 : 11 (42) w h er e ac c u m u l a t i o n t i m e is [] selected phases of no. frequency line 2 linecyc accumtime = 0 : 15 (43) mc is t h e m e t e r co n s t a n t , is t h e an g l e b e tw e e n t h e c u r r en t a nd vol t a g e, li n e f r e q u e n c y i s re a d f rom t h e f r e q re g i ste r or i s k n o w n, and t h e n o . o f pha s es s e lec t ed a r e t h e n u m b er o f z x s e l b i t s s et t o l o g i c 1 in l c y c m o d e (0x17). s t ep 8b: c a lc u l a t e t h e v a l u es t o b e wr i t t e n t o t h e xv a g r e g i s t ers acco r d in g t o t h e fol l o w in g e q u a t i o n . () = 600 , 3 000 , 1 cos 4 2 12 test test v i mc xvag [] vadiv xvahr accumtime 0 : 11 ( 4 4 ) s t ep 9: w r i t e t o xw g an d xv a g . s t ep 10: s et t h e t e s t sys t e m fo r i tes t , v no m , a n d ze r o po w e r f a ct o r (ca l ib ra te v a r ga in). s t ep 11: rep e a t s t ep 7. s t ep 12: re ad t h e xv arhr (0x0 4 t o 0x06) a f t e r th e lener g y in t e r r u p t and s t o r e t h e v a l u es. s t ep 13: c a lc u l a t e t h e v a l u es t o b e wr i t t e n t o t h e xv ar g r e g i s t ers (t o ad j u s t v a r c f t o t h e exp e c t e d value). () = 600 , 3 000 , 1 sin 4 2 12 test test v i mc xvag [] vadiv xvahr accumtime 0 : 11 ( 4 5 ) s t ep 14: w r i t e to xv ar g. s t ep 15: c a lc u l a t e t h e w h /ls b , v a r h / l s b , and v a h/ls b co n s tan t s. xwatthr accumtime v i lsb wh nom test = 600 , 3 ( 4 6 ) xvahr accumtime v i lsb vah nom test = 600 , 3 (47) xvarhr accumtime v i lsb varh nom test = 600 , 3 (48) examp l ewat t gain calibration usin g lin e accumulation this exa m ple only s h o w s p h as e a w a t t cal i b r a t io n. the s t eps o u tlin e d in t h e ga in c a li b r a t i o n u s i n g l i n e a ccum ula ti o n s e c t io n sh o w h o w to ca l i b r a t e w a tt, v a , and v a r . al l t h r e e phas es ca n b e c a lib r a t e d si m u l t a n e o us ly b e c a us e t h er e a r e ni n e en erg y r e g i s t ers . fo r t h i s e x a m p l e , i tes t = 10 a, v no m = 220 v , po w e r fa c t o r = 1, fr e q u e n c y = 50 h z , li nec y c ( 0 x1c) is s et t o 1 f f , a n d mc = 3200 im p / kw hr . t o s et ap cfnu m (0x45) a n d apcfd e n (0x 46) t o t h e calc u l a t e d val u e t o p e r f o r m a co a r s e ad j u s t m e n t o n the im p/kw -hr ra t i o , us e e q ua tio n 27 t o e q ua tion 29: 54 . 0 130 10 500 220 kh 16 = = z apcf nominal () hz 95 . 1 cos 600 , 3 000 , 1 220 10 200 , 3 = = expected apcf 227 hz 95 . 1 hz 541 = = int apcfden u n der t h e t e s t c o n d i t io ns ab o v e, t h e a w a t th r r e g i s t er val u e is 24008d a f t e r t h e le ner g y in t e r r u p t. u s in g e q ua tion 42 and e q u a t i on 4 3 , t h e v a lu e to b e w r i tte n to a w g i s 0 2 d . s accumtime 7 . 1 3 50 2 ff 1 x 0 = = 268 . 2 1 008 , 24 7 . 1 600 , 3 000 , 1 1 220 10 200 , 3 4 2 12 = = s xwg u s i n g eq ua ti o n 46, th e w h / l s b co n s ta n t i s 5 C 10 33 . 4 008 , 24 600 , 3 7 . 1 220 10 = = lsb wh phase c a libration using line accumulatio n the ad e7758 in c l udes a p h as e cal i b r a t io n r e g i st er o n each phas e t o co m p e n s a te fo r smal l phas e er r o r s. l a rg e phas e er r o r s s h o u l d b e co m p en s a t e d b y ad j u s t in g t h e a n t i ali a sin g f i l t ers. the ad e7758 s p h as e cal i b r a t ion is a tim e dela y wi t h dif f er en t w e i g h t s in t h e p o s i ti v e a n d n e g a ti v e di r e cti o n (s ee th e p h a s e c o m p en s a t i o n s e c t io n). si n c e a c u r r en t t r a n sfo r m e r is a s o ur c e o f phas e er r o r , a f i xe d n o mi na l va l u e m a y b e de cide d on to lo ad in t o t h e xph c al (0x3f t o 0x4 1 ) r e gis t er s a t p o w e r - u p . dur i n g cal i b r a t io n, t h is val u e can b e ad j u s t e d fo r ct - t o-ct er r o r .
ade7758 rev. a | page 50 of 68 s t ep 6: c a lc u l a te xp h c a l an d wr i te t o t h e xph c al r e g i st ers (0x3f t o 0x41). f i gur e 82 sh o w s t h e s t eps in v o lv e d i n cal i b r a t i n g t h e phas e us i n g th e lin e accum u la ti o n m o d e . 04443-0-105 step 1 set lcycmode, linecyc and mask registers step 2 set up system for i test , v nom , pf = 0.5 step 3 reset status register step 4 read all xwatthr registers after lenergy interrupt step 5 calculate phase error in degrees for all phases step 6 calculate and write to all xphcal registers () () = error phase s period s xphcal 1 360 4 . 2 C (51) the p e r i o d is a v a i la b l e in t h e ad e7758 f r eq ue n c y r e g i s t er if i t is n o t k n o w n. e q u a t i o n 37 sh o w s h o w t o de t e r m i n e t h e val u e wr i t t e n t o xp h c al usin g t h e p e r i o d r e g i st er m e as ur e m en t (s e e t h e p h as e c a l i b r a t io n u s i n g pu ls e o u t p u t s e c t i o n). i n e q ua t i on 37, t h e 2.4 s is fo r phas e er r o r s t h a t a r e n e g a t i ve . f o r p o si t i v e phas e er r o r , t h e 2.4 s is r e place d b y 4.8 s (s e e t h e p h as e co m p e n sa t i o n s e ct i o n ) . examplepha s e calibration using line accumulation this exa m ple sho w s o n ly p h as e a phas e c a lib r a t io n. al l t h r e e p h c a l r e gi s t e r s ca n be cali b r a t ed s i m u l t a n eo us l y us i n g th e sa m e m e t h o d . fo r t h i s e x a m p l e , i tes t = 10 a, v no m = 220 v , po w e r fa c t o r = 0. 5 ind u c t iv e , and fre q u e n c y = 50 h z . f i g u re 82. phas e cal i br at io n u s ing l i ne ac cu m u lat i on wi t h i te s t , v no m , a nd 0.5 i n d u c t iv e p o w e r fac t o r , t h e exam ple ad e7758 met e r s h o w s 12036d in t h e a w a t thr (0x01) r e g i s t er . f o r uni t y p o w e r fac t o r (a f t er ga in cal i b r a t io n), t h e m e t e r sh o w s 24 020d in t h e a w a t thr r e g i st er . this is e q u i v a l e n t to 2 6 l s b s of e r ror . s t ep 1: i f t h e v a lues w e r e cha n g e d a f t e r ga i n cal i b r a t io n, st ep 1, s t ep 3, a nd s t ep 4 f r o m th e ga in cal i b r a t io n s h o u ld be r e p e a t ed t o co nf igur e t h e l c y c mo d e a nd line cy c r e g i s t ers. s t ep 2: s et t h e tes t sys t em fo r i te s t , v no m , a n d 0.5 p o w e r fac t o r . the pha s e e r r o r in d e g r e e s using e q ua t i on 50 is ?0.07. s t ep 3: re s et t h e in t e r r u p t s t a t u s r e g i s t er b y r e adin g rst a tus (0x1a). () = ? ? ? ? ? ? = 07 . 0 C 3 00215 . 0 sin C arc error phase ste p 4 : t h e x w a t t h r re g i s t e r s shou l d b e re a d af te r t h e linecy c i n t e r r u p t . m e as ur e t h e p e r c en t er r o r in t h e e n erg y re g i ste r re a d i n g s ( a w a t t h r , b w a t t h r , a n d c w a t t h r ) co m p a r e d t o t h e en erg y r e g i s t e r r e adin gs a t uni t y p o w e r fac t o r (a f t er ga in cal i b r a t io n) usin g e q ua tio n 49. the r e adin gs a t uni t y p o we r f a c t or s h ou l d h a ve b e e n re p e a t e d af te r t h e g a i n ca l i b r a t io n and sto r e d fo r us e in t h e pha s e c a lib r a t io n r o u t i ne. u s i n g e q u a t i on 3 7 , t h e v a lu e w r i tte n to a p hc a l ( 0 x 3 f ) , i f a t 50 h z t h e f r eq (0x10) r e g i s t er = 2083d , is 21d . 21 07 . s 6 . 9 2083 1 360 s 4 . 2 = ? ? ? ? ? ? ? ? = aphcal 2 2 C 1 1 5 = = = = pf pf pf xwatthr xwatthr xwatthr error (49) power offset calibration us ing line accumu l a tion p o we r of f s e t c a l i br a t i o n s h ou l d b e u s e d f o r out s t a n d i ng p e r f o r ma n c e o v er a wi de d y namic ra n g e (1,00 0 :1). c a l i b r a t ion o f t h e p o w e r o f fs et is don e a t o r clos e t o t h e mi nim u m c u r r en t . the ad e7758 has p o w e r o f fs et r e g i s t ers f o r wa t t s a nd v a r , xw a t tos (0x39 t o 0x3b) a n d xv ar os (0x3c t o 0x3e). of fs ets in t h e v a me as ur e m e n t a r e co m p en s a t e d b y ad j u s t i n g th e rm s o f fse t r e gi s t e r s (see t h e cali b r a t i o n o f ir ms a n d vr ms of fs et s e c t io n). f i gur e 83 sh o w s t h e s t eps t o cal i b r a t e t h e p o wer o f fse t s us i n g th e li n e a c cum ula tio n m o d e . s t ep 5: c a lc u l a te t h e pha s e e r r o r in d e g r e e s usin g t h e fol l o w ing eq ua ti o n . () ? ? ? ? ? ? = 3 C error arcsin error phase (50)
ade7758 rev. a | page 51 of 68 04443-0-107 step 1 set lcycmode, linecyc and mask registers step 2 set up system for i test , v nom @ pf = 1 step 3 reset status register step 4 read all xwatthr registers after lenergy interrupt step 5 set up system for i min , v nom @ pf = 1 end for step 10 read all xvarh r after lenergy interrupt for step 10, calculate xvaros for all phases yes no tested @ i min ? step 7 calculate xwattos for all phases for step 10, write to all xvaros registers for step 10, pf = 0 step 8 write to all xwattos registers step 9 set up system for i test , v nom @ pf = 0 step 10 repeat step 3 to step 8 for xvarhr, xvaros calibration step 6 f i gure 8 3 . p o wer o ffset c a l i b r a t i o n using li ne a c cu m u la tio n s t ep 1: i f t h e v a lues w e r e cha n g e d a f t e r ga i n cal i b r a t io n, st ep 1, s t ep 3, a nd s t ep 4 f r o m th e ga in cal i b r a t io n s h o u ld be r e p e a t ed t o co nf igur e t h e l c y c mo d e , linecy c, an d mas k r e g i s t ers . s t ep 2: s et t h e tes t sys t em fo r i te s t , v no m , a n d u n i t y p o w e r fac t o r . s t ep 3: re s et t h e in t e r r u p t s t a t u s r e g i s t er b y r e adin g rst a tus (0x1a). s t ep 4: re ad al l xw a t hr en erg y r e g i s t ers (0x01 t o 0x03) a f t e r t h e lener g y i n t e r r u p t an d s t or e t h e val u es. s t ep 4a: re ad t h e freq (0x10) r e g i s t er if t h e f r e q uen c y is unk n o w n. s t ep 5: s et t h e tes t sys t em fo r i min , v no m , a n d u n i t y p o w e r fac t o r . s t ep 6: re p e a t st ep 3 an d s t ep 4 . s t ep 7: c a lc u l a te t h e val u e t o b e wr i t t e n t o t h e x w a t t o s re g i ste r s a c c ord i n g to t h e f o l l o w i n g e q u a t i ons . test min min i test i i i i xwatthr i xwatthr offset test min C C = (52) [] 29 2 4 0 : 11 = clkin accumtime offset xwattos (53) w h er e ac c u m u l a t i o n t i m e is de f i n e d in e q u a t i on 43 an d xw a t thri te s t is t h e val u e in t h e e n erg y r e g i s ter a t i te s t , a n d xw a t thri min is t h e val u e in t h e en erg y r e g i s t e r a t i min . s t ep 8: w r i t e t o al l xw a t tos r e g i s t ers (0x39 to 0x3b). s t ep 9: s et t h e tes t sys t em fo r i te s t , v no m , a n d z e r o po w e r f a ct o r (ca l ib ra te v a r ga in). s t ep 10: rep e a t s t eps 3, 4, a nd 5 .
ade7758 rev. a | page 52 of 68 calibration of irms and vr ms offs et s t ep 11: c a lc u l a t e t h e v a l u e wr i t t e n t o t h e xv aros r e g i s t ers a c c ord i n g to t h e f o l l o w i n g e q u a t i ons . irmsos an d v r msos a r e us e d t o can c e l n o is e a nd o f fs et co n t r i b u t i on s f r o m t h e i n p u ts. the cal i b r a t ion m e t h o d is t h e s a m e w h et h e r c a lib r a t i n g usin g t h e p u ls e o u t p uts o r line acc u m u la t i on. re a d i n g t h e r e g i st ers is r e q u ir e d fo r t h is cal i b r a t io n si n c e t h er e is n o r m s p u ls e o u t p u t . the r m s o f fs et c a l i br a t i o n shou l d b e p e r f or me d b e f ore v a g a i n c a l i br a t i o n . the r m s o f fs et c a lib r a t ion als o r e m o v e s o f fs et f r o m t h e v a calc u l a t i o n . f o r t h is r e as o n , n o v a o f fs et r e g i s ter exis ts in t h e ad e7758. test min min test i i i xvarhr i xvarhr offset C C = (54) 29 2 4 ] 0 : 11 [ + clkin accumtime offset xvaros (55) exa m ple pow e r of fs et ca li b r a t i o n us i n g li ne accumulation the lo w - p a s s f i lt er us e d t o ob t a i n t h e r m s m e asur em e n ts is n o t ide a l, t h er efo r e i t is r e co mm e nde d t o sy n c hr oni z e t h e r e adi n g s wi t h t h e zer o cros sin g s o f t h e v o l t a g e w a v e fo r m an d t o a v era g e a fe w me as ur e m e n ts w h en r e adi n g t h e r m s r e g i s ters. this exa m ple only s h o w s p h as e a o f t h e phas e ac t i v e p o w e r of f s e t c a l i br a t i o n . b o t h a c t i v e a n d re a c t i ve p o w e r of f s e t f o r a l l p h a s e s c a n be ca l i b r a t ed s i m u l t a n e o u s l y u s i n g th e m e th od expla i n e d in t h e p o w e r of fs et c a lib r a t ion u s in g l i ne a c cu m u l a ti o n s e cti o n . the ad e7758 i r ms meas ur emen t is linea r o v er a 500:1 ra n g e , a nd t h e v r ms m e as ur e m en t is line a r o v er a 20 :1 ra n g e . t o m e as ur e t h e v o lt a g e v r ms o f fs et (xvrmsos), m e as ur e r m s val u es a t tw o di f f er en t n o nzer o c u r r en t le ve ls, fo r exa m ple , v no m and v no m /20. t o m e asur e t h e c u r r en t r m s o f fs et (irmsos), me as ur e r m s val u es a t t w o dif f er en t n o nzer o c u r r en t lev e ls, f o r exa m p l e , i te s t and i ma x /500). this tran s l a t es t o thr e e te st c o nd i t i o ns : i te s t and v no m , i max /500 a n d v no m , i te s t and v no m /20. f i gur e 84 s h o w s a f l o w c h a r t f o r calib r a t in g t h e r m s m e as ur e m en ts. fo r t h i s e x a m p l e , i tes t = 10 a, i min = 100 ma, v no m = 220 v , po w e r f a c t o r = uni t y , fr e q u e n c y = 50 h z , an d linecy c = 0xfff . at i te s t , th e exa m p l e ad e7758 m e t e r sh o w s 19 2489d in t h e a w a t t h r (0x01) r e gis t er a f t e r ga in calib r a t io n a t 0xfff lin e cy c l e s . a t i min , th e m e t e r sh o w s 1919d in t h e a w a t thr r e g i s t er . b y usin g e q ua tio n 52, t h is is eq ui valen t t o th e 6 ls bs o f o f fs et, t h er efo r e , usin g e q ua t i on 53, t h e v a l u e wr i t t e n t o aw a t t o s i s 9 4 d . 95 . 5 10 C 1 . 0 1 . 0 489 , 192 C 10 1919 = = offset 39 . 94 2 mhz 10 65 . 13 4 6 29 = = awattos
ade7758 rev. a | page 53 of 68 04443-0-102 step 1 set configuration registers for zero crossing on all phases step 2 set interrupt mask for zero crossing on all phases step 3 step 4 read rms registers step 5 write to xvrmsos xirmsos set up system for i test , v nom set up system for i max /500, v nom set up system for i test , v nom /20 start tested all phases? yes no tested all conditions? 2 3 1 step 4a choose n n = 0 step 4d read xirms xvrms step 4e calculate the average of n samples step 4b reset interrupt status register end n = n + 1 n = n? no yes yes no step 4c interrupt? f i g u re 84. r m s ca li br at i o n r o ut in e s t ep 1: s et co nf igura t io n r e g i st e r s fo r zer o cr os s i n g s o n al l phas es b y wr i t i n g t h e va l u e 0x38 t o t h e lcy c mo d e r e g i s t er (0x17). this s e ts al l o f th e zxs e l b i t s t o l o g i c 1. s t ep 2: s et t h e i n t e r r u p t mask reg i s t er fo r zer o -cr o s s in g det e c t io n o n al l p h as es b y wr i t in g 0xe00 t o th e mas k [0:24] r e g i s t er (0x18). this s e ts al l o f t h e zx b i t s t o l o g i c 1. s t ep 3: s et u p t h e cal i b r a t io n syst em fo r o n e o f t h e t h r e e t e st condi t ion s : i te s t and v no m , i max /500 and v no m , i te s t and v no m /2 0. s t ep 4: re ad t h e r m s r e g i s t ers a f t e r t h e zer o -cr o s s in g i n t e r r u p t a nd t a ke a n a v e r a g e o f n s a m p les. this is r e commende d to ge t th e m o s t s t a b le rm s r e a d in g s . th i s p r oced ur e i s d e ta ile d in f i gur e 84s t ep s 4a thr o u g h 4 e . s t ep 4a . c h o o s e t h e n u m b er o f s a m p les, n, t o b e a v era g e d . s t ep 4b . res et t h e in t e r r u p t s t a t us r e g i s t er b y r e adi n g rst a tus (0x1a). s t ep 4c. w a i t for t h e zer o -cr o s s i n g in t e r r u p t. w h e n t h e zer o - cr os sin g in ter r u p t o c c u rs, m o v e t o s t ep 4d . s t ep 4d . read t h e xirms (0x0a) a n d xvrms (0x0c) r e gis t er s. th e s e v a l u es wi l l b e a v era g e d i n s t ep 4e . s t ep 4e: a v era g e t h e n s a m p les o f xirms a n d xvrms. th e a v era g e d val u es wi l l b e us e d i n s t ep 5. s t ep 5: w r i t e t o th e xvrmsos ( 0 x36 t o 0x38) a nd xirmsos (0x33 t o 0x35) r e g i s t ers acco r d in g t o t h e f o l l o w in g eq ua t i o n s. = irmsos ( )( ) 2 2 2 2 2 2 C C 384 , 16 1 test max/x rms test max/x rms max/x test i i i i i i ? ? ? (56) w h er e i te s t -r ms a nd i ma x/x-rm s a r e th e rm s r e gi s t er v a l u e s wi t h o u t t h e o f fs et co r r e c t i o n fo r t h e in pu t i te s t and i max/ x , r e s p ecti v e l y . nom nom/20 rms nom nom/20 rms nom/20 nom v v v v v v vrmsos C C 64 1 ? ? = (57) w h er e v no m - r m s a nd v n o m/20-rms a r e t h e r m s r e g i s t er val u es wi t h o u t t h e o f fs et co r r e c t i o n fo r t h e i n p u t v no m and v no m / 2 0 - r ms , r e s p ecti v e l y .
ade7758 rev. a | page 54 of 68 examp l ecali bration of rms offsets fo r t h i s e x a m p l e , i tes t = 10 a, i ma x = 100 a, v nom = 220 v , v f u llsc a le = 500 v , po w e r fa c t o r = 1, a n d fr e q u e n c y = 50 h z . wi t h i te s t and v no m , th e exa m p l e ad e7758 met e r sh o w s 0x34266 in t h e airms (0x0a) r e g i s t er a nd 0x1 0 b0a3 in t h e av r m s ( 0 x 0 d ) r e g i s t e r . a t i ma x/500 , t h e exa m ple m e t e r sh o w s 0x19f in airm s. a t v no m / 2 0 , t h e exa m ple m ete r s h o w s 0xd65 b in t h e a v rms reg i s t er . th e s e a r e t h e a v er a g e v a l u e o f 20 s a m p les sy n c hro n o u s t o t h e zer o cr os sin g s o f al l t h r e e p h as es. u s in g this da t a , ?3d is wr i t t e n to a v rmsos (0x33) a n d ?1004 d i s w r it te n to a i r m s o s ( 0 x 3 6 ) re g i ste r s ac c ord i n g to t h e e q ua tion 56 and e q u a tio n 57. ? = 384 , 16 1 xirmsos () ( ) () 1104 88 . 1103 10 C 2 . 0 606 , 213 2 . 0 C 415 10 2 2 2 2 2 ? = ? = ( ) ( ) () 3 047 . 3 220 C 11 795 , 093 , 1 11 C 54875 220 64 1 ? = ? = = xvrmsos this exa m ple sho w s t h e c a lc u l a t io n s an d m e as u r em e n ts fo r p h as e a only . h o w e v e r , al l t h r e e xirms a nd x v rms r e g i s t ers ca n b e r e ad si m u l t a n e o us ly t o c o m p u te t h e va l u es fo r e a ch xirmsos a nd x v rmsos r e g i ster . checksum register the ad e7758 has a c h ec ks u m reg i s t er che cks u m[7:0] (0x7e) t o en s u r e the da t a b i ts r e cei v ed in the las t s e r i al r e ad o p era t ion a r e no t co r r u p t e d . th e 8- b i t ch e c ksum r e g i s t er is r e s et b e fo r e t h e f i rs t b i t (ms b o f t h e r e g i s t er t o b e r e ad) is p u t o n t h e d o ut p i n. dur i n g a s e r i al r e ad o p er a t io n, w h en each da t a b i t b e co m e s a v a i la b l e o n t h e r i sin g e d g e o f sclk, t h e b i t is adde d to t h e che c ksu m r e g i ster . i n t h e e nd o f t h e s e r i a l r e ad o p era t ion, t h e c o n t e n t o f t h e che c ks u m r e g i s t er is e q ual t o t h e s u m o f al l t h e on es i n t h e r e g i s ter p r e v io us ly r e ad . u s i n g t h e ch e c ks u m r e g i s ter , t h e us er ca n det e r m i n e if an er r o r has o c c u r r ed d u r i ng th e last r e ad o p era t io n. n o t e t h a t a r e ad t o t h e c h eck s um r e gi s t e r also g e n e ra t e s a c h ec k s um o f th e ch eck s um re g i ste r it s e l f . 04443-0-049 dout addr: 0x7e checksum register content of registers (n-bytes) f i gure 85. che c ks um r e g i s t er f o r s e ri a l inter f a c e r e ad ade7758 interrupts the ad e7758 in t e r r u p ts a r e ma na g e d thr o ug h th e in t e r r u p t s t a t us r e g i s t er ( s t a tus[23:0], a ddr es s 0x19) and t h e in t e r r u p t mas k r e g i st er (mas k[23:0], a ddr es s 0x18). w h en a n in t e r r u p t ev en t o c c u rs in th e ad e7758, t h e co r r es p o ndin g f l a g in t h e in t e r r u p t st a t us r e g i s t er is s et t o a l o g i c 1 (s e e t a b l e 20). i f t h e mas k b i t fo r t h is in ter r u p t in t h e in t e r r u p t mask r e g i s t er is l o g i c 1, t h en t h e ir q log i c o u t p u t go es ac t i v e lo w . the f l a g b i ts in t h e in t e r r u p t s t a t us r e g i s t er ar e s et ir r e s p e c t i v e o f t h e s t a t e o f t h e mask b i ts. t o det e r m i n e t h e s o ur ce o f t h e in t e r r u p t, t h e s y ste m m a s t e r ( m c u ) s h ou l d p e r f or m a re a d f rom t h e re s e t in t e r r u p t st a t us r e g i s t er w i t h r e s et. this is achi e v e d b y ca r r yin g out a re a d f rom r s t a t u s , a d d r e s s 0 x 1 a . t h e ir q output go e s l o g i c h i g h on c o m p l e t i on of t h e i n te r r upt s t atu s re g i ste r re a d co mman d (s e e t h e i n t e r r u p t t i min g s e c t io n). w h en ca r r yin g o u t a r e ad wi t h r e s et, t h e ad e7758 is desig n e d t o en s u r e tha t no in t e r r u p t e v en ts a r e mis s e d . i f an i n t e r r u p t e v e n t o c c u rs j u st as t h e in t e r r u p t s t a t us r e g i s t er is b e in g r e ad , t h e e v en t is n o t los t a nd t h e ir q log i c o u t p u t is gua r a n teed t o g o log i c hig h f o r the d u ra t i on o f t h e in t e r r u p t st a t us r e g i s t er da t a t r an sfer b e fo r e go in g lo g i c lo w a g a i n to i ndic a te t h e p e nding i n ter r u p t. n o te t h a t t h e r e s et i n t e r r u p t b i t in t h e s t a t us r e g i s t er is hig h fo r o n ly o n e c l o c k c y c l e; th en i t g o es back t o 0. using the ade7758 interrupts with an mcu fi g u r e 8 7 s h ow s a t i m i n g d i a g r a m t h at i l lu s t r a t e s a s u g g e s t e d im p l em en ta tio n o f ad e7758 in t e r r u p t ma na g e m e n t usin g an mcu . a t t i me t 1 , th e ir q li n e g o e s a c ti v e lo w in di ca ti n g th a t o n e o r m o r e in ter r u p t ev en ts ha v e o c c u r r ed in t h e ad e7758. the ir q log i c o u t p u t sh o u ld be t i e d t o a n e g a ti v e e d g e tr ig g e r e d exter nal i n t e r r up t on t h e mc u . on de t e c t ion o f t h e neg a t i ve e d g e , t h e m c u s h o u ld be co n f ig ur ed t o s t a r t ex ecu t i n g i t s in t e r r u p t s e r v ic e r o u t i n e (is r ). on en t e r i n g t h e is r , al l in t e r r u p ts sh o u ld b e dis a b l e d us in g t h e g l ob al i n t e r r u p t mas k b i t. a t t h is p o in t, t h e mcu exte r n al in ter r u p t f l a g can b e cle a r e d i n o r d er t o ca pt ur e i n t e r r u p t e v en ts t h a t o c c u r d u r i n g t h e c u r r en t isr . w h en t h e mc u in t e r r u p t f l a g is cle a r e d , a r e ad f r o m t h e r e s e t i n t e r r u p t s t a t us reg i s t er wi t h r e s e t is ca r r ie d o u t. (t h i s ca uses t h e ir q line t o b e r e s e t log i c hig h ( t 2 )s e e t h e in t e r r u pt ti m i n g s e c t i o n . ) the res e t i n t e r r u p t s t a t us r e g i ster con t e n t s a r e u s e d t o deter mi ne t h e s o u r c e of t h e i n t e r r upt ( s ) a n d h e n c e t h e a p p r o p r i a te ac t i on t o b e t a k e n. i f a subs e q ue n t in t e r r u p t e v en t o c c u rs d u r i ng t h e isr ( t 3 ) th a t ev e n t i s r e co r d ed b y t h e mcu exter nal in t e r r u p t f l a g b e in g s et a g a i n. o n r e t u r n ing f r o m t h e i s r , t h e g l ob al i n t e r r u p t mas k b i t is cle a r e d (s a m e in s t r u c t i o n c y cle) a n d t h e ext e r n al i n t e r r u p t f l a g us es t h e m c u t o j u m p to i t s is r on ce aga i n. this en sur e s t h a t t h e m c u do es n o t miss an y ext e r n al i n t e r r u p ts. th e r e s et b i t i n t h e st a t us r e g i st er is a n excep t io n t o t h is, a nd is o n ly hig h fo r o n e clo c k c y cle a f t e r a r e s et e v e n t.
ade7758 rev. a | page 55 of 68 interrup t timi ng the ad e7758 s e r i al i n ter face s e c t io n sh o u l d b e r e view e d f i rs t be f o r e r e v i e w in g th i s in t e rr u p t ti m i n g sect i o n . a s p r e v i o us l y des c r i b e d , w h e n t h e ir q o u t p u t g o es lo w , t h e m c u is r m u s t r e ad t h e i n ter r u p t s t a t us r e g i s t e r in o r d er t o de ter mi n e t h e s o ur ce o f t h e i n ter r u p t . w h en r e adi n g t h e i n t e r r u p t s t a t us r e gi s t e r co n t en ts , th e ir q o u t p u t is s et hig h on t h e l a s t fal l i n g e d g e o f sclk o f t h e f i rst b y te t r a n sfer (r e a d in ter r u p t s t a t us r e g i s t er co mmand). th e ir q o u t p u t is he ld hig h un til the las t b i t o f t h e n e xt 8 - b i t t r a n sfer is s h if t e d ou t (i n t er r u p t s t a t us r e g i s t er co n t e n t s )s e e f i gur e 8 7 . i f a n i n t e r r u p t is p e n d in g a t th i s tim e , t h e ir q o u t p u t g o es lo w a g a i n. i f n o in t e r r u p t is pe n d i n g, th e ir q output re m a i n s h i g h . ade7758 serial interface the ad e7758 has a b u i l t-in s p i in t e r f ace . the s e r i al in ter face o f th e ad e7758 is made o f f o ur sig n als: sclk, d i n, d o ut , a nd cs . t h e se rial c l oc k f o r a da ta tra n s f e r i s a p p l i e d a t th e s c l k log i c in p u t . th is log i c in p u t h a s a s c hmi t t trigg e r in p u t s t ru ct u r e tha t al lo ws s l o w r i sin g (a n d f a l l ing) c l o c k edg e s t o be us e d . al l da t a t r a n sfer o p era t io n s a r e syn c hr o n ize d t o t h e s e r i a l c l o c k. da ta is s h if t e d in t o the ad e7758 a t t h e d i n log i c in p u t o n t h e fal l i n g e d g e o f sclk. d a t a is s h if te d o u t o f t h e ad e77 58 a t t h e d o ut log i c o u t p u t o n a r i sin g edg e o f s c lk. the cs log i c in p u t is t h e chi p s e le c t in pu t. this in p u t is us e d w h e n m u l t i p le de vice s s h a r e t h e s e r i a l b u s. a fal l i n g e d g e o n cs also r e s ets t h e s e r i al in t e r f ace and pl aces t h e ad e77 58 in co mm u- nica t i o n s m o de. the cs in p u t sh ou ld be dr i v en lo w f o r th e e n ti r e da ta tra n s f e r o p e r a t i o n . b r i n gi n g cs hig h d u r i n g a da t a t r a n sfer o p era t io n a b o r ts t h e t r a n sfer a n d pl ace t h e s e r i al b u s i n a hig h i m p e dance st a te. t h e cs lo gic in p u t ma y b e tied lo w if th e ad e7758 is th e onl y de vic e o n the s e r i al b u s. h o w e ver , wi t h cs tied lo w , al l ini t ia t e d da t a tra n sf er o p era t io n s m u s t be f u l l y co m p let e d . th e ls b o f e a ch r e g i s t er m u s t b e t r an sfer r e d bec a us e t h er e is n o o t h e r wa y o f b r in g i n g t h e ad e7758 bac k in t o co mm un ic a t io n s m o de wi t h o u t r e s e t t in g t h e e n t i r e de vic e , i . e . , p e r f o r ming a s o f t wa re res e t using bi t 6 o f t h e opm o d e [ 7 :0 ] r e g i s t er , a d dr ess 0x13. the f u nc tio n ali t y o f the ad e7758 is a c c e ss i b l e v i a s e ve r a l on - c h i p re g i ste r s ( s e e fi g u re 8 6 ) . t h e co n t e n ts o f t h es e r e g i s t ers can b e u p da t e d o r r e ad usin g t h e on- c h i p s e r i al in ter face . af t e r a f a l l i n g e d ge o n cs , the ad e7758 is place d in comm unic a t io n s m o d e . i n comm u n ic a t io n s m o de , t h e ad e7758 exp e c t s the f i rs t co mm unica t io n t o b e a wr i t e t o t h e i n t e r n a l co mm unica t i o n s r e gis t er . th e da t a w r i t t e n t o t h e c o m m u n i c a t i o n s r e g i st er co n t ai n s t h e addr es s and s p e c if ies t h e n e xt da t a t r an sfer t o b e a r e ad or a wr i t e co mma n d . th er efo r e , al l da ta tran sf er o p era t io n s wi t h th e ad e7758, whet h e r a r e ad o r a wr i t e, m u st b e g i n w i t h a wr i t e to t h e co mm unic a t io n s re g i ste r . 04443-0-052 communications register in out in out in out in out in out register no. 1 register no. 2 register no. 3 register no. n?1 register no. n register address decode din dout f i gur e 8 6 . a ddr essing ade7 75 8 regi ster s via the comm uni c a t io ns regi ster 04443-a - 050 global interrupt mask isr return global interrupt mask reset clear mcu interrupt flag read status with reset (0x1a) isr action (based on status contents) mcu interrupt flag set program sequence t 1 t 2 t 3 jump to isr jump to isr irq f i g u re 87. a d e 7 7 5 8 in terrupt ma na g e ment status register contents 04443- 0- 051 sclk din dou t read status register command t 1 cs 00 0 1 000 db15 db8 db7 db0 1 t 9 t 11 t 12 irq f i gure 8 8 . ade7 758 interrupt ti mi ng
ade7758 rev. a | page 56 of 68 the co mm uni c a t io n s r e g i st er is a n 8- b i t wr i t e- o n ly r e g i s t er . th e ms b det e r m i n e s w h et h e r t h e next da t a t r an sfer o p era t io n is a r e ad or a wr i t e. the s e v e n l s bs con t a i n t h e addres s o f t h e reg i st e r to b e ac cess e d . s e e t a b l e 12 fo r a m o r e det a i l e d des c r i p t ion. f i gur e 89 an d f i gur e 90 sh o w t h e da ta tran sf er s e q u en ces f o r a re a d a n d w r ite op e r a t i o n , re sp e c t i vely . on co m p let i o n o f a da ta tran sf er (r ead o r wr i t e) , th e ad e7758 o n ce a g a i n en t e rs in t o co mm un ica t io n s m o d e , i.e ., t h e n e xt in st r u c t io n fol l o w e d m u st b e a wr i te t o t h e comm un ic a t io n s re g i ste r . 04443-0-053 multibyte communications register write din sclk dou t read data address 0 cs f i g u re 89. r e ad ing d a t a f r o m t h e a d e 7 7 5 8 v i a t h e s e ri al i n ter f ac e 04443- 0- 054 communications register write din s cl k address 1 cs multibyte read data f i g u re 90. w r it ing d a t a t o t h e a d e 7 7 58 v i a th e s e r i a l i n ter f ace a da t a tra n sf er is co m p let e d w h en t h e ls b o f t h e ad e7758 re g i ste r b e i n g a d d r e s s e d ( f or a w r it e or a re a d ) i s t r ans f e r re d to o r f r o m the ade7758. ade7758 serial write operation the s e r i al wr i t e s e q u e n ce t a k e s place as fol l o w s. w i t h t h e ad e7758 in comm unic a t io n s m o de and t h e cs in p u t log i c lo w , a wr i t e t o t h e comm unic a t io n s reg i s t er t a k e s place f i rs t. the ms b o f t h is b y te t r a n sfer m u s t b e s et t o 1, i ndi ca t i n g t h a t t h e n e xt da t a t r an sfer o p era t io n is a wr i te t o t h e r e g i s t er . th e s e v e n ls b s o f t h i s b y t e con t ai n t h e addr es s o f t h e reg i ster to b e wr i t t e n t o . th e ad e7758 s t a r ts s h if t i n g in t h e r e g i s t er da ta on t h e n e xt f a l l i n g e d ge of s c l k . a l l re m a i n i n g bit s of re g i ste r d a t a are s h if t e d i n o n t h e fal l in g e d g e o f t h e s u b s e q ue n t sclk p u ls es (s ee f i gur e 91). a s explai n e d e a rlier , t h e da t a w r i t e is ini t i a t e d b y a wr i te t o t h e co m m uni c a t i o n s r e gi s t e r f o llo w ed b y th e d a t a . duri n g a da ta wr i te o p era t io n t o th e ad e7758 , da ta is tran sf er r e d t o al l o n - chi p r e g i s t ers on e b y t e a t a t i me . af t e r a b y t e is t r a n sfer r e d in to t h e s e r i al p o r t , t h er e is a f i ni te t i m e d u ra t i o n b e fo r e t h e con t e n t in t h e s e r i al p o r t b u f f er is tra n sf er r e d t o o n e o f t h e ad e7758 on - c h i p re g i ste r s . a l t h ou g h a n o t he r b y te t r ans f e r to t h e s e r i a l p o r t ca n s t a r t w h i l e t h e p r e v io u s b y t e is b e in g t r a n sfer r e d t o t h e des t ina t ion r e g i s t er , t h is s e co nd-b yte t r a n sfer s h o u ld n o t f i nish un til a t lea s t 900 n s a f t e r th e en d o f th e p r e v i o us b y t e tra n s f e r . this f u n c t i o n a l i t y is exp r ess e d i n t h e t i mi n g sp e c if ica t ion t 6 (se e f i gur e 91). i f a wr i te o p era t io n is a b o r t e d d u r i ng a b y te t r a n sfer ( cs b r o u g h t hig h ), t h e n t h a t b y t e i s n o t wr i t ten t o t h e dest in a t ion r e g i st er . d e st in a t ion r e g i st ers ma y b e u p t o 3 b y t e s wi de (s e e t h e a cces s in g t h e ad e7758 on-chi p reg i s t ers s e c t io n). th er ef o r e , t h e f i rst b y te s h i f t e d i n t o t h e s e r i al p o r t a t d i n i s t r a n sfer r e d t o t h e m o st sig n if i c a n t b y te (ms b ) o f t h e de s t ina t i o n r e g i s t er . i f t h e dest ina t io n r e g i st er is 12 b i t s wi de , fo r exa m ple , a t w o- b y t e da ta tra n s f e r m u s t tak e p l a c e . th e da ta i s al wa ys a s s u m e d t o b e r i g h t j u s t if ie d; t h er efo r e , in t h is cas e , t h e fo ur ms bs o f t h e f i rst b y te wo u l d b e ig n o re d and t h e four l s b s o f t h e f i rs t b y t e w r i t te n t o th e ad e7758 w o u l d b e t h e f o ur ms bs o f th e 12-b i t w o r d . f i g u re 9 2 i l lu st r a te s t h i s e x am pl e. 04443-0-055 din sclk cs t 2 t 3 t 1 t 4 t 5 t 7 t 6 t 8 command byte most significant byte least significant byte 1a 6 a 4 a5 a3 a2 a1 a0 db7 db0 db7 db0 t 7 f i gure 91. s e ri al inter f ace wri t e t i mi n g d i ag r a m 04443-0-056 sclk din x x x x db11 db10 db9 db8 db7 db6 db5 db4 db3 db2 db1 db0 most significant byte least significant byte f i gure 92. 1 2 -bit s e ri al w r ite o p er ati o n
ade7758 rev. a | page 57 of 68 ade7758 serial read operation dur i n g a da ta r e ad o p er a t io n f r o m t h e ad e775 8, da ta is s h if t e d o u t a t t h e d o ut log i c o u t p u t o n t h e r i sin g e d ge o f sclk. a s was t h e cas e wi t h t h e da t a wr i t e o p era t ion, a da t a r e ad m u s t b e p r eced ed wi th a w r i t e t o t h e co m m uni c a t i o n s r e gi s t e r . w i t h t h e ad e7 758 in co mm unica t io n s m o de and cs log i c lo w , a n 8- b i t wr i t e t o t h e comm u n ic a t io n s r e g i s t er f i rs t t a k e s place . t h e ms b o f th i s b y t e tra n s f e r m u s t be a 0, in d i ca ti n g th a t t h e n e xt da t a t r an sfer o p era t io n is a r e ad . th e s e v e n ls bs o f t h is b y t e con t a i n t h e addr es s o f t h e reg i s t er t h a t is t o b e r e ad . the ad e7758 s t a r ts s h if tin g o u t o f t h e r e g i st er da t a o n t h e n e xt ri s i n g ed g e o f sc l k (see f i g u r e 93). a t th i s po i n t, t h e d o u t log i c o u t p u t s w i t ch es f r o m a hig h i m p e dan c e s t a t e and s t a r ts dr i v in g t h e da t a b u s. al l r e mainin g b i ts o f r e g i s ter da t a a r e s h if t e d o u t on su bs e q u e n t s c l k r i sin g e d g e s. the s e r i al in t e r f ace e n t e rs co mm un ic a t io ns m o de a g a i n as s o o n as t h e r e ad has b e en c o m p let e d . th e d o ut log i c o u t p u t e n ters a hi g h im p e dan c e st a t e o n t h e fal l in g e d g e o f t h e las t s c lk p u ls e . th e re a d op e r a t i o n m a y b e a b or te d b y br i n g i ng t h e cs log i c in p u t hig h b e fo r e t h e da t a t r a n sfer is co m p let e d . th e d o ut ou t p u t en t e rs a hig h i m p e dan c e s t a te o n t h e r i sin g e d ge o f cs . w h en an ad e7 758 r e g i s t er is addr es s e d f o r a r e ad o p er a t ion, t h e en t i r e co n t e n ts o f t h a t r e g i s ter a r e t r a n sfer r e d t o t h e s e r i al p o r t . this al lo ws th e ad e7758 t o m o dif y i t s on-c hi p r e g i st ers wi t h o u t t h e r i sk o f co r r u p t i n g da t a d u r i n g a m u l t ib yt e t r a n sfer . n o t e t h a t w h en a r e ad o p era t ion fol l o w s a wr i te o p era t ion, t h e r e ad co mmand (i .e ., wr i te t o comm unic a t io n s reg i s t er) sh o u ld n o t ha p p en f o r a t leas t 1.1 s a f t e r t h e en d o f t h e w r i t e o p e r a t i o n . i f t h e r e ad comma nd is s e n t w i t h in 1 . 1 s o f t h e wr i t e o p er a t ion, t h e last b y te o f t h e wr i t e o p er a t i o n ma y b e los t . 04443-0-057 sclk cs t 1 t 10 t 13 0 a6 a4 a5 a3 a2 a1 a0 db0 db7 db0 db7 din dout t 11 t 12 command byte most significant byte least significant byte t 9 f i g u re 93. s e ri al int e r f ace r e ad ti ming d i ag r a m
ade7758 rev. a | page 58 of 68 accessing the ade7758 on-chip registers all ade7758 functionality is accessed via the on-chip registers. each register is accessed by first writing to the communications register and then transferring the register data. for a full description of the serial interface protocol, see the ade7758 serial interface section. communications register the communications register is an 8-bit, write-only register that controls the serial data transfer between the ade7758 and the host processor. all data transfer operations must begin with a write to the communications register. the data written to the communications register determines whether the next operation is a read or a write and which register is being accessed. table 12 outlines the bit designations for the communications register. table 12. communications register bit location bit mnemonic description 0 to 6 a0 to a6 the seven lsbs of the communications register specif y the register for the data transfer operation. table 13 lists the address of each ade7758 on-chip register. 7 w/ r when this bit is a logic 1, the data transf er operation immediately following the write to the communications register is interpreted as a write to the ade7758. when this bit is a logic 0, the data transfer operation immediately following the write to the communications register is interpreted as a read operation. db7 db6 db5 db4 db3 db2 db1 db0 w/ r a6 a5 a4 a3 a2 a1 a0 table 13. ade7758 register list address [a6:a0] name r/w 1 length default value description 0x00 reserved C reserved. 0x01 awatthr r 16 0 watt-hour accumulation register for phase a. active power is accumulated over time in this read-only register. the aw atthr register can hold a maximum of 0.52 seconds of active energy information with full-scale analog inputs before it overflows (see the active energy calculat ion section). bit 0 and bit 1 of the compmode register determine how the active energy is processed from the six analog inputs. 0x02 bwatthr r 16 0 watt-hour accumu lation register for phase b. 0x03 cwatthr r 16 0 watt-hour accumu lation register for phase c. 0x04 avarhr r 16 0 var-hour accumulation register for ph ase a. reactive power is accumulated over time in this read-only register. th e avarhr register ca n hold a maximum of 0.52 seconds of reactive energy informatio n with full-scale analog inputs before it overflows (see the reactive energy calc ulation section). bit 0 and bit 1 of the compmode register determine how the reactive energy is processed from the six analog inputs. 0x05 bvarhr r 16 0 var-hour accumulation register for phase b. 0x06 cvarhr r 16 0 var-hour accumu lation register for phase c. 0x07 avahr r 16 0 va-hour accumulation register for phas e a. apparent power is accumulated over time in this read-only register. th e avahr register can hold a maximum of 1.15 seconds of apparent energy information with full-scale analog inputs before it overflows (see the apparent energy ca lculation section). bit 0 and bit 1 of the compmode register determine how the ap parent energy is processed from the six analog inputs. 0x08 bvahr r 16 0 va-hour accumulation register for phase b. 0x09 cvahr r 16 0 va-hour accumulation register for phase c. 0x0a airms r 24 0 phase a current channel rms register. th e register contains the rms component of the phase a input of the current channel. the source is selected by data bits in the mode register. 0x0b birms r 24 0 phase b current channel rms register. 0x0c cirms r 24 0 phase c current channel rms register. 0x0d avrms r 24 0 phase a voltage channel rms register. 0x0e bvrms r 24 0 phase b voltage channel rms register.
ade7758 rev. a | page 59 of 68 address [a6:a0] name r/w 1 length default value description 0x0f cvrms r 24 0 phase c voltage channel rms register. 0x10 freq r 12 0 frequency of the line input estimated by the zero-crossing processing. it can also display the period of the line in put. bit 7 of the lcycmode register determines if the reading is frequency or period. default is frequency. data bit 0 and bit 1 of the mmode register deter mine the voltage channel used for the frequency or period calculation. 0x11 temp r 8 0 temperature register. this register contai ns the result of the latest temperature conversion. please refer to the temperature measurement section for details on how to interpret the content of this register. 0x12 wform r 24 0 waveform register. this register contains the digitized waveform of one of the six analog inputs or the digitized power waveform. the source is selected by data bit 0 to bit 4 in the wavmode register. 0x13 opmode r/w 8 4 operational mode register. this register defines the general configuration of the ade7758 (see table 14). 0x14 mmode r/w 8 0xfc measurement mode register. this register defines the channel used for period and peak detection measurements (see table 15). 0x15 wavmode r/w 8 0 waveform mode register. this register defines the channel and sampling frequency used in the waveform sampling mode (see table 16). 0x16 compmode r/w 8 0x1c this register configures the formula appl ied for the energy and line active energy measurements (see table 17). 0x17 lcycmode r/w 8 0x78 this register configures the line cycl e accumulation mode for watt-hr, var-hr, and va-hr (see table 18). 0x18 mask r/w 24 0 the irq mask register. it determines if an interrupt event generates an active- low output at the irq pin (see the ade7758 interrupts section). 0x19 status r 24 0 the irq status register. this register cont ains information regarding the source of the ade7758 interrupts (see th e ade7758 interrupts section). 0x1a rstatus r 24 0 same as the status register, except that its contents are reset to 0 (all flags cleared) after a read operation. 0x1b zxtout r/w 16 0xffff zero-cross timeout register. if no zero crossing is detected within the time period specified by this register, the interrupt request line ( irq ) goes active low for the corresponding line voltage. the maximum timeout period is 2.3 seconds (see the zero-crossing detection section). 0x1c linecyc r/w 16 0xffff line cycle register. the content of this register sets the number of half-line cycles that the active, reactive, and appa rent energies are accumulated for in the line accumulation mode. 0x1d sagcyc r/w 8 0xff sag line cycle register. this register specifies the number of consecutive half- line cycles where voltage channel input may fall below a threshold level. this register is common to the three line voltage sag detection. the detection threshold is specified by the saglvl regi ster (see the line voltage sag detection section). 0x1e saglvl r/w 8 0 sag voltage level. this register specif ies the detection threshold for the sag event. this register is common to all three phases line voltage sag detections. see the description of sagcyc register for details. 0x1f vpintlvl r/w 8 0xff voltage peak level interrupt threshold regist er. this register sets the level of the voltage peak detection. bit 5 to bit 7 of the mmode register determine which phases are to be monitored. if the sele cted voltage phase exceeds this level, the pkv flag in the irq status register is set. 0x20 ipintlvl r/w 8 0xff current peak level interrupt threshold regist er. this register sets the level of the current peak detection. bit 5 to bit 7 of the mmode register determine which phases to are be monitored. if the select ed current phase exceeds this level, the pki flag in the irq status register is set. 0x21 vpeak r 8 0 voltage peak register. this register co ntains the value of the peak voltage waveform that has occurred within a fixed number of half-line cycles. the number of half-line cycles is set by the linecyc register. 0x22 ipeak r 8 0 current peak register. this register hold s the value of the peak current waveform that has occurred within a fixed number of half-line cycles. the number of half- line cycles is set by the linecyc register.
ade7758 rev. a | page 60 of 68 address [a6:a0] name r/w 1 length default value description 0x23 gain r/w 8 0 pga gain register. this register is used to adjust the gain selection for the pga in the current and voltage channels (see the analog inputs section). 0x24 avrmsgain r/w 12 0 phase a vrms gain register. the range of the voltage rms calculation can be adjusted by writing to this register. it has an adjustment range of 50% with a resolution of 0.0244%/lsb. 0x25 bvrmsgain r/w 12 0 phase b vrms gain register. 0x26 cvrmsgain r/w 12 0 phase c vrms gain regsiter. 0x27 aigain r/w 12 0 phase a current gain register. the range of the current rms calculation can be adjusted by writing to this register. it has an adjustment range of 50% with a resolution of 0.0244%/lsb. adjusting this register also scales the watt and var calculation. not for use with mo de 0 of consel, compmode[0:1]. 0x28 bigain r/w 12 0 phase b current gain register. 0x29 cigain r/w 12 0 phase c current gain regsiter. 0x2a awg r/w 12 0 phase a watt gain register. the range of the watt calculation can be adjusted by writing to this register. it has an adjustment range of 50% with a resolution of 0.0244%/lsb. 0x2b bwg r/w 12 0 phase b watt gain register. 0x2c cwg r/w 12 0 phase c watt gain register. 0x2d avarg r/w 12 0 phase a var gain register.the range of the var calculation can be adjusted by writing to this register. it has an adjustment range of 50% with a resolution of 0.0244%/lsb. 0x2e bvarg r/w 12 0 phase b var gain register. 0x2f cvarg r/w 12 0 phase c var gain register. 0x30 avag r/w 12 0 phase a va gain register. the range of the va calculation can be adjusted by writing to this register. it has an adjustment range of 50% with a resolution of 0.0244% / lsb. 0x31 bvag r/w 12 0 phase b va gain register. 0x32 cvag r/w 12 0 phase c va gain register. 0x33 avrmsos r/w 12 0 phase a voltage rms offset correction register. 0x34 bvrmsos r/w 12 0 phase b voltage rms offset correction register. 0x35 cvrmsos r/w 12 0 phase c voltage rms offset correction register. 0x36 airmsos r/w 12 0 phase a current rms offset correction register. 0x37 birmsos r/w 12 0 phase b current rms offset correction register. 0x38 cirmsos r/w 12 0 phase c current rms offset correction register. 0x39 awattos r/w 12 0 phase a watt offset calibration register. 0x3a bwattos r/w 12 0 phase b wa tt offset calibration register. 0x3b cwattos r/w 12 0 phase c wa tt offset calibration register. 0x3c avaros r/w 12 0 phase a var offset calibration register. 0x3d bvaros r/w 12 0 phase b var offset calibration register. 0x3e cvaros r/w 12 0 phase c var offset calibration register. 0x3f aphcal r/w 7 0 phase a phase calibration register. the phase relationship between the current and voltage channel can be adjusted by wr iting to this signed 7-bit register (see the phase compensation section). 0x40 bphcal r/w 7 0 phase b phase calibration register. 0x41 cphcal r/w 7 0 phase c phase calibration register. 0x42 wdiv r/w 8 0 active energy register divider. 0x43 vardiv r/w 8 0 reactive energy register divider. 0x44 vadiv r/w 8 0 apparent energy register divider. 0x45 apcfnum r/w 16 0 active power cf scaling numerator register. the content of this register is used in the numerator of the apcf output scaling. bits [15:13] indicate reverse polarity active power measurement for phase a, phas e b, and phase c in order, i.e., bit 15 is phase a, bit 14 is phase b, etc. 0x46 apcfden r/w 12 0x3f active power cf scaling denominator regist er. the content of this register is used in the denominator of the apcf output scaling.
ade7758 rev. a | page 61 of 68 address [a6:a0] name r/w 1 length default value description 0x47 varcfnum r/w 16 0 reactive power cf scaling numerator regist er. the content of this register is used in the numerator of the varcf output scaling. bits [15:13] indicate reverse polarity reactive power measurement for phas e a, phase b, and phase c in order, i.e., bit 15 is phase a, bit 14 is phase b, and so on. 0x48 varcfden r/w 12 0x3f reactive power cf scaling denominator regi ster. the content of this register is used in the denominator of the varcf output scaling. 0x49 to 0x7d reserved ? ? ? reserved. 0x7e chksum r 8 ? checksum register. the content of this register represents the sum of all the ones in the last register read from the spi port. 0x7f version r 8 ? version of the die. 1 r/w: read/write capability of the register. r: read-only register. r/w: register that can be both read and written. operational mode register (0x13) the general configuration of the ade7758 is defined by writing to the opmode register. table 14 summarizes the functionality of each bit in the opmode register. table 14. opmode register bit location bit mnemonic default value description 0 dishpf 0 the hpfs (high-pass filter) in all current channel inputs are disabled when this bit is set. 1 dislpf 0 the lpfs (low-pass filter) in all current channel inputs are disabled when this bit is set. 2 discf 1 the frequency outputs apcf and va rcf are disabled when this bit is set. 3 to 5 dismod 0 by setting these bits, ade7758s adcs can be turned off. in normal operation, these bits should be left at logic 0. dismod[2:0] description 0 0 0 normal operation. 1 0 0 redirect the voltage inputs to the signal paths for the current channels and the current inputs to the sign al paths for the voltage channels. 0 0 1 switch off only the current channel adcs. 1 0 1 switch off current channel adcs and redirect the current input signals to the voltage channel signal paths. 0 1 0 switch off only the voltage channel adcs. 1 1 0 switch off voltage channel adcs and redirect the voltage input signals to the current channel signal paths. 0 1 1 put the ade7758 in sleep mode. 1 1 1 put the ade7758 in power-down mode. 6 swrst 0 software chip reset. a data transfer to the ade7758 should not take place for at least 18 s after a software reset. 7 reserved 0 this should be left at 0.
ade7758 rev. a | page 62 of 68 measurement mode register (0x14) the configuration of the period and peak measurements made by the ade7758 is defined by writing to the mmode register. table 15 summarizes the functionality of each bit in the mmode register. table 15. mmode register bit location bit mnemonic default value description 0 to 1 freqsel 0 these bits are used to select the so urce of the measurement of the voltage line frequency. freqsel1 freqsel0 source 0 0 phase a 0 1 phase b 1 0 phase c 1 1 reserved 2 to 4 peaksel 7 these bits select the phases used for the voltage an d current peak registers. setting bit 2 switches the ipeak and vpeak registers to hold the absolute va lues of the largest current and voltage waveform (over a fixed number of half-line cycles) from phase a. the number of half-line cycles is determined by the content of the linecyc register. at the end of the linecyc number of half-line cycles, the content of the registers is replaced with the new peak values. similarly, setting bit 3 turns on the peak detection for phase b and bit 4 is fo r phase c. note that if more th an one bit is set, the vpeak and ipeak registers can hold values from two different phases, i.e., the voltage and current peak are independently processed (see the pe ak current detection section). 5 to 7 pkirqsel 7 these bits select the phases used for the peak in terrupt detection. setting bit 5 switches on the monitoring of the absolute current and voltage wavef orm to phase a. similarly, setting bit 6 turns on the waveform detection for phase b and bit 7 is for phas e c. note that more than one bit can be set for detection on multiple phases. if the absolute valu es of the voltage or current waveform samples in the selected phases exceeds the preset level spec ified in the pkvlvl or pkilvl registers, the corresponding bit(s) in the stat us registers are set (see the peak current detection section). waveform mode register (0x15) the waveform sampling mode of the ade7758 is defined by writing to the wavmode register. table 16 summarizes the functionality of each bit in the wavmode register. table 16. wavmode register bit location bit mnemonic default value description 0 to 1 phsel 0 these bits are used to select the phase of the waveform sample. phsel[1:0] source 0 0 phase a 0 1 phase b 1 0 phase c 1 1 reserved 2 to 4 wavsel 0 these bits are us ed to select the type of waveform. wavsel[2:0] source 0 0 0 current 0 0 1 voltage 0 1 0 active power multiplier output 0 1 1 reactive power multiplier output 1 0 0 va multiplier output -others- reserved 5 to 6 dtrt 0 these bits are used to select the data rate. dtrt[1:0] update rate 0 0 26.0 ksps (clkin/3/128) 0 1 13.0 ksps (clkin/3/256) 1 0 6.5 ksps (clkin/3/512) 1 1 3.3 ksps (clkin/3/1024) 7 vacf 0 setting this bit to logic 1 switches the varc f output pin to an output frequency that is proportional to the total apparent power (va). in the default state, logic 0, the varcf pin outputs a frequency proportional to the total reactive power (var).
ade7758 rev. a | page 63 of 68 computational mode register (0x16) the computational method of the ade7758 is defined by writing to the compmode register. table 17 summarizes the functionality o f each bit in the compmode register. table 17. compmode register bit location bit mnemonic default value description 0 to 1 consel 0 these bits are used to select the input to the energy accumulation registers. registers consel[1, 0] = 00 consel[1, 0] = 01 consel[1, 0] = 10 awatthr va ia va (ia C ib) va (iaCib) bwatthr vb ib 0 0 cwatthr vc ic vc (ic C ib) vc ic avarhr va ia va ( ia C ib ) va (iaCib) bvarhr vb ib 0 0 cvarhr vc ic vc ( ic C ib ) vc ic avahr va rms ia rms va rms ia rms va rms a rms bvahr vb rms ib rms (va rms + vc rms )/2 ib rms va rms ib rms cvahr vc rms ic rms vc rms ic rms vc rms ic rms consel[1, 1] is reserved. note: ia , ib , and ic are ia, ib, and ic phase shifted by C90, respectively. 2 to 4 termsel 7 these bits are used to select the phases to be included in the apcf and varcf pulse outputs. setting bit 2 enables phase a (the inputs to awatthr and avarhr re gisters) to be included. bit 3 and bit 4 are for phase b and phase c, respectively. setting all three bits enables the sum of all three phases to be included in the frequency outputs (see the acti ve power frequency output and the reactive power frequency output sections). 5 abs 0 setting this bit places the apc f output pin in absolute only mode. namely, the apcf output frequency is proportional to the sum of the absol ute values of the watt-hour accumulation registers (awatthr, bwatthr, and cwatthr). note that this bit only affects the apcf pin and has no effect on the content of the corresponding registers. 6 savar 0 setting this bit places the varcf output pin in the signed adjusted mode. namely, the varcf output frequency are proportional to the sign-adjusted sum of the var-hour accumulation registers (avarhr, bvarhr, and cvarhr). the sign of the var is determined from the sign of the watt calculation from the corresponding phase, i.e., the sign of the var is flipped if the sign of the watt is negative, and if the watt is positive, there is no change to the sign of the var. note that this bit only affects the varcf pin and has no effect on th e content of the corresponding registers. 7 noload 0 setting this bit activate s the no-load threshold in the ade7758.
ade7758 rev. a | page 64 of 68 line cycle accumulation mode register (0x17) the functionalities involved the line-cycle accumulation mode in the ade7758 are defined by writing to the lcycmode register. t able 18 summarizes the functionality of each bit in the lcycmode register. table 18. lcycmode register bit location bit mnemonic default value description 0 lwatt 0 setting this bit places the watt-hour accumula tion registers (awatthr, bwatthr, and cwatthr registers) into line-cycle accumulation mode. 1 lvar 0 setting this bit places the var-hour accumula tion registers (avarhr, bvarhr, and cvarhr registers) into line-cycle accumulation mode. 2 lva 0 setting this bit places the va-h our accumulation registers (ava hr, bvahr, and cvahr registers) into line-cycle accumulation mode. 3 to 5 zxsel 7 these bits select the phases used for counting the number of ze ro crossings in the line-cycle accumulation mode. bit 3, bit 4, and bit 5 select phase a, phase b, and phase c, respectively. more than one phase can be selected for the zero-cro ssing detection, and the accumulation time is shortened accordingly. 6 rstread 1 setting this bit enables the read-with-reset for a ll the watthr, varhr, and vahr registers for all three phases, i.e., a read to those registers resets the registers to 0 after the content of the registers have been read. this bit should be set to logic 0 when the lwatt, lvar, or lva bits are set to logic 1. 7 freqsel 0 setting this bit causes the freq (0x10) register to display the pe riod, instead of the frequency of the line input.
ade7758 rev. a | page 65 of 68 interrupt mask register (0x18) when an interrupt event occurs in the ade7758, the irq logic output goes active low if the mask bit for this event is logic 1 in the mask register. the irq logic output is reset to its default collector open state when the rstatus register is read. table 19 describes the function of each bit in the interrupt mask register. table 19. function of each bit in the interrupt mask register bit location interrupt flag default value description 0 aehf 0 enables an interrupt when there is a change in bit 14 of any one of the three watthr registers, i.e., the watthr register is half full. 1 rehf 0 enables an interrupt when there is a change in bit 14 of any one of the three varhr registers, i.e., the varhr register is half full. 2 vaehf 0 enables an interrupt when there is a 0 to 1 transition in the msb of any one of the three vahr registers, i.e., the vahr register is half full. 3 saga 0 enables an interrupt when there is a sag on the line voltage of the phase a. 4 sagb 0 enables an interrupt when there is a sag on the line voltage of the phase b. 5 sagc 0 enables an interrupt when there is a sag on the line voltage of the phase c. 6 zxtoa 0 enables an interrup t when there is a zero-crossing timeout detection on phase a. 7 zxtob 0 enables an interrupt when there is a zero-crossing timeout detection on phase b. 8 zxtoc 0 enables an interrup t when there is a zero-crossing timeout detection on phase c. 9 zxa 0 enables an interrupt when there is a zero crossing in the voltage channel of phase a (see the zero-crossing detection section). 10 zxb 0 enables an interrupt when there is a zero crossing in the voltage channel of phase b (see the zero-crossing detection section). 11 zxc 0 enables an interrupt when there is a zero crossing in the voltage channel of phase c (see the zero-crossing detection section). 12 lenergy 0 enables an interrupt when the energy accumulations over linecyc are finished. 13 reserved 0 reserved. 14 pkv 0 enables an interrupt when the voltage input selected in the mmode register is above the value in the pkvlvl register. 15 pki 0 enables an interrupt when the current input sele cted in the mmode register is above the value in the pkilvl register. 16 wfsm 0 enables an interrupt when da ta is present in the wavemode register. 17 revpap 0 enables an interrupt when there is a sign change in the watt ca lculation among any one of the phases specified by the termsel bi ts in the compmode register. 18 revprp 0 enables an interrupt when there is a sign change in the var ca lculation among any one of the phases specified by the termsel bi ts in the compmode register. 19 seqerr 0 enables an interrupt when the zero crossing from phase a is not followed by the zero crossing of phase c but with that of phase b.
ade7758 rev. a | page 66 of 68 interrupt status register (0x19)/reset interrupt status register (0x1a) the interrupt status register is used to determine the source of an interrupt event. when an interrupt event occurs in the ade7 758, the corresponding flag in the interrupt status register is set logic high. the irq pin goes active low if the corresponding bit in the interrupt mask register is set logic high. when the mcu services the interrupt, it must first carry out a read from the interrupt status register to determine the source of the interrupt. all the interrupts in the interrupt status register stay at their logic high state after an event occurs. the state of the interrupt bit in the interrupt status register is reset to its default value once the reset interrupt status r egister is read. table 20. interrupt status register bit location interrupt flag de fault value event description 0 aehf 0 indicates that an interrupt was caused by a change in bit 14 among any one of the three watthr registers, i.e., the watthr register is half full. 1 rehf 0 indicates that an interrupt was caused by a change in bit 14 among any one of the three varhr registers, i.e., the varhr register is half full. 2 vaehf 0 indicates that an interrupt was caused by a 0-to-1 transition in bit 15 among any one of the three vahr registers, i.e., the vahr register is half full. 3 saga 0 indicates that an interrupt was caused by a sag on the line voltage of the phase a. 4 sagb 0 indicates that an interrupt was caused by a sag on the line voltage of the phase b. 5 sagc 0 indicates that an interrupt was caused by a sag on the line voltage of the phase c. 6 zxtoa 0 indicates that an interrupt was caused by a missing zero crossing on the line voltage of the phase a. 7 zxtob 0 indicates that an interrupt was caused by a missing zero crossing on the line voltage of the phase b. 8 zxtoc 0 indicates that an interrupt was caused by a missing zero crossing on the line voltage of the phase c. 9 zxa 0 indicates a detection of a rising edge zero crossing in the voltage channel of the phase a. 10 zxb 0 indicates a detection of a rising edge zero crossing in the voltage channel of the phase b. 11 zxc 0 indicates a detection of a rising edge zero crossing in the voltage channel of the phase c. 12 lenergy 0 in line energy accumulation, it indicates the end of an integration over an integer number of half-line cycles (linec yc), see the calibration section. 13 reset 1 indicates that the 5 v power supply is below 4 v. enables a software reset of the ade7758 and sets the registers back to their default values. this bit in the status or rstatus register is logic high for only one clock cycle after a reset event. 14 pkv 0 indicates that an interrupt was caused when the selected voltage input is above the value in the pkvlvl register. 15 pki 0 indicates that an interrupt was caused when the selected current input is above the value in the pkilvl register. 16 wfsm 0 indicates that new data is present in the waveform register. 17 revpap 0 indicates that an interrupt was caused by a sign change in the watt calculation among any one of the phases specified by the te rmsel bits in the compmode register. 18 revprp 0 indicates that an interrupt was caused by a sign change in the var calculation among any one of the phases specified by the te rmsel bits in the compmode register. 19 seqerr 0 indicates that an interrupt was caused by a zero crossing from phase a not followed by the zero crossing of phase c but by that of phase b.
ade7758 rev. a | page 67 of 68 outline dimensions controlling dimensions are in millimeters; inch dimensions (in parentheses) are rounded-off millimeter equivalents for reference only and are not appropriate for use in design compliant to jedec standards ms-013ad 8 0 0.75 (0.0295) 0.25 (0.0098) 45 1.27 (0.0500) 0.40 (0.0157) 0.33 (0.0130) 0.20 (0.0079) seating plane 0.30 (0.0118) 0.10 (0.0039) 0.51 (0.020) 0.31 (0.012) 2.65 (0.1043) 2.35 (0.0925) 1.27 (0.0500) bsc 24 13 12 1 10.65 (0.4193) 10.00 (0.3937) 7.60 (0.2992) 7.40 (0.2913) 15.60 (0.6142) 15.20 (0.5984) coplanarit y 0.10 f i gure 94. 24-l ead w i de body sm al l o u t lin e p a ck ag e [ s oi c ] (r w - 24) d i mensions sh o w n in mi ll im e t e r s ( i nche s) ordering guide model temperature r a nge description package option ADE7758ARW ?40c to + 85c 24-lead wide b o dy soic rw-24 ADE7758ARW rl ?40c to + 85c 24-lead wide b o dy soic rw-24 (13 reel) ADE7758ARWz 1 ?40c to + 85c 24-lead wide b o dy soic rw-24 ADE7758ARWz r l 1 ?40c to + 85c 24-lead wide b o dy soic rw-24 (13 reel) eval-ade77 58e b e v a l u a t i o n b o a r d 1 z = pb-free part.
ade7758 rev. a | page 68 of 68 notes ? 2004 analo g de vices, inc. all rights reserve d . tra d em arks and registered tra d ema r ks are the prop erty of their respective owners . d04443C0C 9/04(a)


▲Up To Search▲   

 
Price & Availability of ADE7758ARW

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X